google/truth

Truth has an issue when you use assertThat to check a length

wise4rmgod opened this issue · 1 comments

I tried to check the length of a word and it only works with number 5 only, the others give error no matter what
Screenshot 2020-11-19 at 03 05 02

Screenshot 2020-11-19 at 03 04 50

Screenshot 2020-11-19 at 03 05 21

It looks like the string returned by Validate.checkLengthOfWord() was "Error", which has five characters. (You can see that because Truth's failure message contains "string was: Error".

Validate isn't part of Truth, so you might want to check its documentation.