Browse files

add: test functions to all()

fix: invert wrong assertions
add: some assertions
  • Loading branch information...
1 parent dffbab2 commit b0e8b2e2835bf722636353256515a042a93d3bc6 shino_shun committed May 24, 2009
Showing with 13 additions and 4 deletions.
  1. +13 −4 test/vclock_SUITE.erl
View
17 test/vclock_SUITE.erl
@@ -16,7 +16,9 @@
-include("kai.hrl").
-include("kai_test.hrl").
-all() -> [test_desceds_in_single_node].
+all() -> [test_desceds_in_single_node,
+ test_concurrent,
+ test_merge].
test_desceds_in_single_node() -> [].
@@ -51,8 +53,15 @@ test_merge(_Conf) ->
C1 = vclock:merge([A2, B2]),
?assert(vclock:descends(C1, A2)),
?assert(vclock:descends(C1, B2)),
+ ?assertNot(vclock:descends(A2, C1)),
+ ?assertNot(vclock:descends(B2, C1)),
+
C2 = vclock:increment(c, C1),
- ?assertNot(vclock:descends(C2, A2)),
- ?assertNot(vclock:descends(C2, B2)),
- ?assertNot(vclock:descends(C2, C1)),
+
+ ?assert(vclock:descends(C2, A2)),
+ ?assert(vclock:descends(C2, B2)),
+ ?assert(vclock:descends(C2, C1)),
+
+ ?assertNot(vclock:descends(A2, C2)),
+ ?assertNot(vclock:descends(B2, C2)),
ok.

0 comments on commit b0e8b2e

Please sign in to comment.