Advertisement
Guest User

Untitled

a guest
Oct 18th, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.85 KB | None | 0 0
  1.  
  2.  
  3. Checking submission...
  4. You have a code/part1/src/async.erl. Good.
  5. You have a code/part2/src/rps.erl. Good.
  6. You have a code/part2/src/test_rps.erl. Good.
  7.  
  8.  
  9.  
  10. Building warmup async
  11. async.erl: OK
  12.  
  13.  
  14. Checking async API
  15. OK
  16.  
  17.  
  18. Testing async
  19. ======================== EUnit ========================
  20. Simple tests
  21. onlineta_async_tests:14: standard_tests (N =:= wait(new(fun(X) -> X end, N)))...[0.006 s] ok
  22. onlineta_async_tests:16: standard_tests (A = new(fun(X) -> throw(X+1) end, N), N+1 =:= try wait(A), ups catch E -> E end)...[0.006 s] ok
  23. onlineta_async_tests:19: standard_tests (A = new(fun never_returns/0, 42), nothing =:= poll(A))...[0.006 s] ok
  24. onlineta_async_tests: standard_tests (A = new(fun(X) -> X end, N), N =:= wait(A), wait(A) =:= wait(A))...[0.006 s] ok
  25. onlineta_async_tests: standard_tests (A = new(fun(X) -> X+1 end, N), N+1 =:= wait(A), {ok, wait(A)} =:= poll(A))...[0.006 s] ok
  26. [done in 0.009 s]
  27. Concurrency tests
  28. onlineta_async_tests: standard_tests (One process creates the action, another waits for it)...[0.001 s] ok
  29. onlineta_async_tests: standard_tests (More intricate testing of poll and wait)...[0.001 s] ok
  30. [done in 0.004 s]
  31. =======================================================
  32. All 7 tests passed.
  33.  
  34.  
  35.  
  36. Building rps
  37. rock_bot.erl: OK
  38. rps.erl: OK
  39.  
  40.  
  41. Checking rps API
  42. OK
  43.  
  44.  
  45. Type checking(!) Erlang files for Rock-Paper-Scissors
  46. Proceeding with analysis... done in 0m1.19s
  47. done (passed successfully)
  48.  
  49.  
  50. Checking quality of student tests
  51. Compiling test_rps: OK
  52. You have a test_all/0. Good, good.
  53.  
  54. Calling test_rps:test_all()
  55. ================= Output from _your_ tests on _our_ sample solution ================================
  56.  
  57. ======================== EUnit ========================
  58. test_rps: game_test (Rock and paper play best of 3)...[0.003 s] ok
  59. test_rps: drain_in_game_test (Start game, play one round and then drain the server)...ok
  60. test_rps: drain_queue_test (Drain with someone in the queue)...ok
  61. test_rps: invalid_play_test (Make invalid move)...ok
  62. test_rps: no_games_test (Stats with no games)...ok
  63. =======================================================
  64. All 5 tests passed.
  65.  
  66. ================= Your tests are done ==============================================================
  67.  
  68.  
  69. Function coverage report for rps:
  70. 2 calls to rps:drain/3
  71. =ERROR REPORT==== 18-Oct-2019::14:27:28.153341 ===
  72. Error in process <0.124.0> with exit value:
  73. {{assertMatch,[{module,test_rps},
  74. {line,119},
  75. {expression,"Res"},
  76. {pattern,"round_won"},
  77. {value,tie}]},
  78. [{test_rps,'-rock_bot3/2-fun-0-',1,
  79. [{file,"/tmp/tmp.dLg8ckM8X1/test_rps.erl"},{line,119}]},
  80. {test_rps,rock_bot3,2,
  81. [{file,"/tmp/tmp.dLg8ckM8X1/test_rps.erl"},{line,119}]}]}
  82.  
  83. =ERROR REPORT==== 18-Oct-2019::14:27:28.153781 ===
  84. Error in process <0.123.0> with exit value:
  85. {{assertMatch,[{module,test_rps},
  86. {line,109},
  87. {expression,"Res"},
  88. {pattern,"round_lost"},
  89. {value,tie}]},
  90. [{test_rps,'-laser_bot/2-fun-0-',1,
  91. [{file,"/tmp/tmp.dLg8ckM8X1/test_rps.erl"},{line,109}]},
  92. {test_rps,laser_bot,2,
  93. [{file,"/tmp/tmp.dLg8ckM8X1/test_rps.erl"},{line,109}]}]}
  94.  
  95. 9 calls to rps:move/2
  96. 8 calls to rps:queue_up/3
  97. 5 calls to rps:start/0
  98. 2 calls to rps:statistics/1
  99.  
  100. Functionality coverage of our code:
  101. 77.3% of onlineta_coordinator functionality
  102. 67.7% of onlineta_broker functionality
  103.  
  104. Your test score is: acceptable
  105.  
  106.  
  107. Testing rps
  108. ======================== EUnit ========================
  109. Start test
  110. onlineta_rps_tests: rps_suite (starting up an rps server.)...[0.006 s] ok
  111. [done in 0.009 s]
  112. Queue up tests
  113. onlineta_rps_tests: rps_suite (Two players agree on a number of wins.)...[0.002 s] ok
  114. onlineta_rps_tests: rps_suite (Two players wants best-of-3, Other players wants best-of-5.)...[0.002 s] ok
  115. onlineta_rps_tests: rps_suite (No players agree on the number of wins.)...[0.101 s] ok
  116. [done in 0.104 s]
  117. Move tests
  118. onlineta_rps_tests: rps_suite (Rock vs Rock)...[0.001 s] ok
  119. onlineta_rps_tests: rps_suite (Rock vs Paper)...[0.001 s] ok
  120. onlineta_rps_tests: rps_suite (Rock vs Scissors)...[0.001 s] ok
  121. onlineta_rps_tests: rps_suite (Paper vs Rock)...[0.001 s] ok
  122. onlineta_rps_tests: rps_suite (Paper vs Paper)...[0.001 s] ok
  123. onlineta_rps_tests: rps_suite (Paper vs Scissors)...[0.001 s] ok
  124. onlineta_rps_tests: rps_suite (Scissors vs Rock)...[0.001 s] ok
  125. onlineta_rps_tests: rps_suite (Scissors vs Paper)...[0.001 s] ok
  126. onlineta_rps_tests: rps_suite (Scissors vs Scissors)...[0.001 s] ok
  127. onlineta_rps_tests: rps_suite (Best-of-1, 1 rounds)...[0.001 s] ok
  128. onlineta_rps_tests: rps_suite (Best-of-1, 2 rounds)...[0.001 s] ok
  129. onlineta_rps_tests: rps_suite (Best-of-2, 3 rounds)...[0.001 s] ok
  130. [done in 0.004 s]
  131. Statistics tests
  132. onlineta_rps_tests: rps_suite (A single game is ongoing.)...[0.101 s] ok
  133. onlineta_rps_tests: rps_suite (Two players are queued for a game of rock-paper-scissors.)...[0.303 s] ok
  134. onlineta_rps_tests: rps_suite (Two games have finished, the longest had lenght 3.)...[0.013 s] ok
  135. onlineta_rps_tests: rps_suite (Rockers play really long games of rock-paper-scissors.)...[0.020 s] ok
  136. onlineta_rps_tests: rps_suite (A busy server, serving some statistics.)...[0.380 s] ok
  137. onlineta_rps_tests: rps_suite (When all games have finished, statistics should no longer change.)...[0.415 s] ok
  138. [done in 0.420 s]
  139. Drain tests
  140. onlineta_rps_tests: rps_suite (Players, who are qued up at the broker, gets notified when the server is stopping.)...[0.201 s] ok
  141. onlineta_rps_tests: rps_suite (Players in a game gets notified when the system is drained)...ok
  142. [done in 0.204 s]
  143. =======================================================
  144. All 24 tests passed.
  145. ---
  146. I am satisfied.
  147. ---
  148. Found a bug? Are the messages too cryptic?
  149. Let us know at Absalon.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement