Uh oh!
There was an error while loading. Please reload this page.
Update anagram tests - #784
Conversation
vaeng
commented
Jan 25, 2024
Hey, thanks for the PR. Do I understand correctly, that you updated the toml-file to reflect the current state of the tests and rewrote the tests to the format, that is outlined in the wiki? If yes: would you be able to add the missing test cases as well? |
CadeMichael
commented
Jan 25, 2024
Yep! I got configlit to sync and update the toml and then made the changes. How do you mean missing tests? I took out the non included ones and added the new versions. Do you mean add the uuid's to the pre existing tests? |
IsaacG
commented
Jan 25, 2024
The TOML file is metadata about the unit tests. The unit tests list in the cpp test file. Any changes to the TOML files should have a corresponding change in the test.cpp file. |
CadeMichael
commented
Jan 25, 2024
Got it that's what I did, got the changes to sync then updated the cpp test file. Sorry for the imprecise wording I did no manual changes to the TOML I meant made changes to the cpp test file. |
vaeng
commented
Jan 26, 2024
I am not sure we mean the same thing. Our goal for the track is to implement every test from the problem-specification as a single test case. Unless there is a good reason to skip certain tests, this goal is not yet fulfilled for your implementation. In your test,cpp file some cases are missing their uuid. |
CadeMichael
commented
Jan 28, 2024
Gotcha so even when it says [a0705568-628c-4b55-9798-82e4acde51ca] the test should be included. I assumed it meant include the newer version and skip the old version I'll put the old version back. I added the UUID for the new tests I'll put them in for the old tests as well. |
If it says |
CadeMichael
commented
Jan 28, 2024
should I put the tests back in that say 'include = false' ? |
IsaacG
commented
Jan 28, 2024
Looking at the canonical cases, That's the list of not-reimplemented test cases which ought to show up in the test file. I noticed some of the It looks like the test code in the PR does have all the expected test cases expect the last two which were recently added with |
IsaacG
commented
Jan 28, 2024
The problem spec has 22 test cases but 6 are reimplemented so only 16 ought to show up. |
CadeMichael
commented
Jan 28, 2024
I added the uuid's but not the 'include = false' tests I can add those if needed pls let me know. |
Yes, please include all the tests even the "false" ones if you can. Edit: this might be wrong, please ignore for the time being. |
IsaacG
commented
Jan 28, 2024
In the |
vaeng
commented
Jan 28, 2024
Sorry, I need to look into the 'false'. all the way. I was not aware of the implementation. We do need to discuss the unicode thing though. |
CadeMichael
commented
Jan 28, 2024
got it added all tests |
| [7cc195ad-e3c7-44ee-9fd2-d3c344806a2c] | ||
| description = "does not detect an anagram if the original word is repeated" | ||
| include = false |
There was a problem hiding this comment.
@vaeng Should this test be included in the C++ unit test file or not?
The canonical data says it's superseded and this line of tests.toml says it's not included, but the unit test file now includes it.
vaeng
commented
Jan 29, 2024
@CadeMichael I am sorry for the confusion. I have not seen that some tests are not supposed to be included in the tests, as they are updated. I first thought you had added the You were right not including them. Thanks for adding all the uuids. For the failing tests, we have to update the catch version. At least I think that this is the issue. Unique names are not required for catch2, as long as the tags are different. |
vaeng
commented
Jan 29, 2024
Catch2 v3 changes run fine on my machine, but make problems in the CI. I see two ways:
I have touched on the subject of the latter alternative with @siebenschlaefer in a private conversation. |
siebenschlaefer
commented
Jan 29, 2024
Reversing a Unicode string correctly without a library is nearly impossible, unless you only want to handle some basic/simple cases. We could include ICU in our docker image but I'd vote against it. Proper Unicode handling would make this a different exercise, and a much harder one. |
vaeng
commented
Jan 29, 2024
I also vote to not include unicode tests. The correct way would be to have an |
IsaacG
commented
Jan 29, 2024
Yup. This would be where you'd set that manually. |
CadeMichael
commented
Jan 29, 2024
Alright I will remove the include false tests and the unicode tests and add include = false to those. The commit will be in within 5 min of this comment. |
Followed the guide for updating testcases, using configlet to sync test.toml and making the updates in the testfile.