1212
1313import javax .ejb .EJB ;
1414
15- import static org .hamcrest .MatcherAssert .*;
16- import static org .hamcrest .Matchers .*;
15+ import static org .hamcrest .MatcherAssert .assertThat ;
16+ import static org .hamcrest .Matchers .equalTo ;
17+ import static org .hamcrest .Matchers .is ;
1718
1819/**
1920 * @author Jakub Marchwicki
@@ -35,7 +36,7 @@ public static Archive<?> deployment() {
3536 .addClass (AccountSessionBean .class )
3637 .addAsManifestResource (EmptyAsset .INSTANCE , "beans.xml" );
3738 }
38-
39+
3940 /**
4041 * JSR 318: Enterprise JavaBeans, Version 3.1
4142 * 3.4.7.2 Session Object Identity / Stateless Session Beans
@@ -54,17 +55,17 @@ public void should_be_identical_beans() {
5455 @ Test
5556 @ InSequence (2 )
5657 public void should_deposit_amount_on_first_account () {
57- assertThat (account1 .getAmount (), is ( equalTo (0f ) ));
58+ assertThat (account1 .getAmount (), equalTo (0f ));
5859
5960 String actual = account1 .deposit (deposit_amount );
6061
6162 assertThat (actual , is (equalTo ("Deposited: " + deposit_amount )));
62- assertThat (account1 .getAmount (), is ( equalTo (deposit_amount ) ));
63+ assertThat (account1 .getAmount (), equalTo (0f ));
6364 }
6465
6566 @ Test
6667 @ InSequence (3 )
6768 public void should_contain_already_deposited_amount_on_second_account () {
68- assertThat (account2 .getAmount (), is ( equalTo (deposit_amount )));
69+ assertThat (account2 .getAmount (), equalTo (account1 . getAmount ( )));
6970 }
70- }
71+ }
0 commit comments