Hi Justin,

thanks for finding that ... guess when porting all these thousands of 
statements, I must have missed one or two "replace: ' == ' with ').isEqualTo('" 
__

Well the main reason was probably, that I wanted to replace the 
"assertTrue(A==B)" with something like "assertEqual(A, B)" as this outputs the 
"expected" and the actual "value" and hereby provides a little more information 
than a simple "was false". So I had the option of converting it to JUint 
"Assert.assertEquals" or update it to AssertJ's 
"Assertions.assertThat().isEqualTo()" which I think is a little more readable 
(Depending on the framework the order of "expected" and "actual" do tend to 
vary and with this notation it's clear) ... and I think we had an Issue and 
corresponding discussion to using AssertJ which allows much more detailed 
checks.

Chris



Am 09.02.18, 02:53 schrieb "Justin Mclean" <jus...@classsoftware.com>:

    Hi,
    
    BTW any reason you use assertThat form AssertJ rather than the one built 
into Junit 4? Just curious no strong views either way.
    
    You might want to fix a couple of your assertThat’s for instance this:
    
    assertThat(tpdu.getTpduCode() == TpduCode.CONNECTION_REQUEST);
    
    Isn’t probably doing what you think it is. :-)
    
    Thanks,
    Justin

Reply via email to