ada icon indicating copy to clipboard operation
ada copied to clipboard

Missing test coverage for encode_json for values smaller than 0x1f

Open Uzlopak opened this issue 2 years ago • 3 comments

What is the problem this feature will solve?

increases test coverage

What is the feature you are proposing to solve the problem?

I was investigating ada. I saw that you do 2 * c and was wondering if a bitshift makes a difference c << 1 but then I realized that if replace with just returning '0', then ctest --output-on-failure --test-dir build will pass all the tests. So there is missing test coverage.

I guess that the compiler will create the same bytecode for 2 * c and c << 1. But it would make sense to have test coverage.

What alternatives have you considered?

No response

Uzlopak avatar Sep 26 '23 21:09 Uzlopak

Would you like to open a pull request for the missing test?

anonrig avatar Sep 27 '23 23:09 anonrig

I have no clue where to put it :D

Uzlopak avatar Sep 27 '23 23:09 Uzlopak

I have no clue where to put it :D

test/basic_tests.cpp works

anonrig avatar Oct 10 '23 16:10 anonrig