Skip to content

Instantly share code, notes, and snippets.

View kinow's full-sized avatar
💭
😬

Bruno P. Kinoshita kinow

💭
😬
View GitHub Profile
@kinow
kinow / TestLinkBUG5079_1.java
Created July 18, 2012 21:14
TestLinkBUG5079_1.java
/*
* The MIT License
*
* Copyright (c) <2012> <Bruno P. Kinoshita>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@kinow
kinow / TestLinkBUG5079_1.log
Created July 18, 2012 21:22
TestLinkBUG5079_1.log
-- Updating TC status --
-- TC 34 --
latest exec: null
report TC result resp: ReportTCResultResponse [operation=reportTCResult, overwrite=null, status=null, message=Success!, executionId=45, bugIDStatus=null, customFieldStatus=null]
latest exec: Execution [id=45, buildId=2, testerId=1, status=b, testPlanId=40, testCaseVersionId=35, testCaseVersionNumber=1, executionType=2, notes=Sample report 26566954696025]
-- END --
-- TC 32 --
latest exec: null
report TC result resp: ReportTCResultResponse [operation=reportTCResult, overwrite=null, status=null, message=Success!, executionId=46, bugIDStatus=null, customFieldStatus=null]
latest exec: Execution [id=46, buildId=2, testerId=1, status=b, testPlanId=40, testCaseVersionId=33, testCaseVersionNumber=1, executionType=2, notes=Sample report 26567542696449]
@kinow
kinow / parse_tlbug.pl
Created July 18, 2012 21:49
parse_tlbug.pl
#!/usr/bin/perl
use strict;
use warnings;
my $file = "TestLinkBUG5079_1.log";
my $latestResult = "";
my $currentResult = "";
my $flag = 0;
open(FL, "<$file");
@kinow
kinow / parse_tlbug.pl.log
Created July 18, 2012 21:50
parse_tlbug.pl.log
OK! Previous result: null - Current result: 26566954696025
OK! Previous result: null - Current result: 26567542696449
OK! Previous result: null - Current result: 26567966963365
OK! Previous result: null - Current result: 26568505621654
OK! Previous result: null - Current result: 26568930979954
OK! Previous result: null - Current result: 26569474182641
OK! Previous result: null - Current result: 26569885866906
OK! Previous result: null - Current result: 26570343898223
OK! Previous result: null - Current result: 26570865849795
OK! Previous result: null - Current result: 26571299389086
@kinow
kinow / T.java
Created July 20, 2012 02:38
T.java
/*
* The MIT License
*
* Copyright (c) <2012> <Bruno P. Kinoshita>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@kinow
kinow / testlink.java
Created July 26, 2012 03:45
Sample TestLink call
Exception: java.lang.IllegalArgumentException: Failed to instantiate class hudson.plugins.selenium.configuration.global.SeleniumGlobalConfiguration from {"configuration":{"browsers":[{"binary":"","kind":"hudson.plugins.selenium.configuration.browser.ChromeBrowser","maxInstances":"5","stapler-class":"hudson.plugins.selenium.configuration.browser.ChromeBrowser","version":""},{"binary":"","kind":"hudson.plugins.selenium.configuration.browser.ChromeBrowser","maxInstances":"5","stapler-class":"hudson.plugins.selenium.configuration.FileConfiguration","version":""}],"display":"","port":"4444","rcBrowserSessionReuse":false,"rcBrowserSideLog":false,"rcDebug":false,"rcLog":"","rcTrustAllSSLCerts":false,"stapler-class":"hudson.plugins.selenium.configuration.CustomConfiguration","value":"0"},"matcher":{"label":"selenium","stapler-class":"hudson.plugins.selenium.configuration.global.matcher.NodeLabelMatcher","value":"2"},"name":"selenium-basic-config"}
Stacktrace:
javax.servlet.ServletException: java.lang.IllegalArgumentE
@kinow
kinow / gist:3747204
Created September 19, 2012 02:00
commons-functor trunk code
import org.apache.commons.functor.generator.GenerateWhile;
import org.apache.commons.functor.generator.util.IntegerRange;
public class T {
public static void main(String[] args) {
UnaryPredicate<Integer> lessThanTwo = new UnaryPredicate<Integer>() {
public boolean test(Integer obj) {
return obj != null && obj < 2;
@kinow
kinow / gist:3747207
Created September 19, 2012 02:01
commons-functor FUNCTOR-14 branch
import org.apache.commons.functor.generator.loop.GenerateWhile;
import org.apache.commons.functor.generator.range.IntegerRange;
public class T {
public static void main(String[] args) {
UnaryPredicate<Integer> lessThanTwo = new UnaryPredicate<Integer>() {
public boolean test(Integer obj) {
return obj != null && obj < 2;
@kinow
kinow / gist:3747224
Created September 19, 2012 02:06
Ranges API
import org.apache.commons.functor.generator.loop.GenerateWhile;
import org.apache.commons.functor.generator.range.CharacterRange;
import org.apache.commons.functor.generator.range.IntegerRange;
import org.apache.commons.functor.generator.range.Ranges;
public class T {
public static void main(String[] args) {
UnaryProcedure<Object> printMe = new UnaryProcedure<Object>() {