Skip to content

Commit

Permalink
add test case for ValuePairUtils
Browse files Browse the repository at this point in the history
  • Loading branch information
gyc567 committed Jul 10, 2016
1 parent 97195f7 commit 7f80086
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/test/java/com/github/eric/ValuePairUtilsTest.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,15 @@ class ValuePairUtilsTest extends Specification {
then:"return value is 2"
ft==2
}
def "valuepair1 with 1,2 ,valuepair2 with 1,valuepari1,rest method shall return valuepair1"() {

given:"valuepair instance with 1,2"
ValuePair vp1=new ValuePair(1,2)
ValuePair vp2=new ValuePair(1,vp1)
when:"call first method of ValuepairUtils"
Object fst=ValuePairUtils.rest(vp2)

then:"return value is 2"
fst!=null
}
}

0 comments on commit 7f80086

Please sign in to comment.