horses
horses copied to clipboard
Property tests in modules
def swap (pair: (a,b)): (b,a) {
case pair of (a,b) -> (b, a)
}
property "two swaps is same as original" (pair: (a,b)) {
swap (swap pair) == pair
}