Guest User

Untitled

a guest
May 23rd, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.40 KB | None | 0 0
  1. import org.junit.jupiter.api.AfterEach;
  2. import org.junit.jupiter.api.Assertions;
  3. import org.junit.jupiter.api.BeforeEach;
  4. import org.junit.jupiter.api.Test;
  5.  
  6. public class ThreadingTest
  7. {
  8. @BeforeEach
  9. public void setUp() throws Exception
  10. {
  11. System.out.println( "Setup command " + Thread.currentThread().toString() );
  12. }
  13.  
  14. @AfterEach
  15. public void tearDown() throws Exception
  16. {
  17. System.out.println( "Teardown command " + Thread.currentThread().getName() );
  18. }
  19.  
  20. @Test
  21. public void test1() throws Exception
  22. {
  23. System.out.println("Test 1 thread is: "+Thread.currentThread().getName());
  24. Assertions.assertTrue( true );
  25. }
  26.  
  27. @Test
  28. public void test2() throws Exception
  29. {
  30. System.out.println("Test 2 thread is: "+Thread.currentThread().getName());
  31. Assertions.assertTrue( true );
  32. }
  33.  
  34. @Test
  35. public void test3() throws Exception
  36. {
  37. System.out.println("Test 3 thread is: "+Thread.currentThread().getName());
  38. Assertions.assertTrue( true );
  39. }
  40.  
  41. @Test
  42. public void test4() throws Exception
  43. {
  44. System.out.println("Test 4 thread is: "+Thread.currentThread().getName());
  45. Assertions.assertTrue( true );
  46. }
  47.  
  48. @Test
  49. public void test5() throws Exception
  50. {
  51. System.out.println("Test 5 thread is: "+Thread.currentThread().getName());
  52. Assertions.assertTrue( true );
  53. }
  54. }
Add Comment
Please, Sign In to add comment