hapijs / lab

Node test utility
Other
739 stars 176 forks source link

Use diffWordsWithSpace instead of diffWords in the console reporter #1055

Open icetbr opened 2 years ago

icetbr commented 2 years ago

Support plan

Context

What are you trying to achieve or the steps to reproduce?

I believe it would be more helpful if white space were to be colored to indicate changes. This is even more problematic when a non break space is in the place of a regular space, so that you can't even see "two spaces" vs "one space"

    test.only('default', async (done) => {
        expect('word1 word2 word3').to.equal('word1  word2 word4')
    });

What was the result you got?

image

What result did you expect?

image