hedy
hedy copied to clipboard
[BUG] Write a test for incorrect keyword placeholders
Describe the bug When parsing the keywords dynamically a few error occurs. Would be nice to fix these. In addition to this, it might be nice to crash the tests on these issues? They shouldn't be possible to exist on main in the first place. The following error is thrown as output:
There is an issue due to a non-existing key in the following line:
`{slaap}` laat Hedy voor een (paar) seconde(n) pauzeren.
There is an issue due to a non-existing key in the following line:
`{Add}` iets `{to_list}` een lijst.
There is an issue due to an empty placeholder in the following line:
We kunnen dus een `{while}` loop gebruiken met `{!=}`.
Describe the bug When parsing the keywords dynamically a few error occurs. Would be nice to fix these. In addition to this, it might be nice to crash the tests on these issues? They shouldn't be possible to exist on main in the first place. The following error is thrown as output:
There is an issue due to a non-existing key in the following line: `{slaap}` laat Hedy voor een (paar) seconde(n) pauzeren. There is an issue due to a non-existing key in the following line: `{Add}` iets `{to_list}` een lijst. There is an issue due to an empty placeholder in the following line: We kunnen dus een `{while}` loop gebruiken met `{!=}`.
Ah good catch!! We are only seeing this now on main since we run the generation on commit since #3333! I agree this should be a failing test instead of an output! We can either copy this code to the unit tests (more clear but a bit more work) or maybe just throw an assert
in the generation instead of a print
?
Describe the bug When parsing the keywords dynamically a few error occurs. Would be nice to fix these. In addition to this, it might be nice to crash the tests on these issues? They shouldn't be possible to exist on main in the first place. The following error is thrown as output:
There is an issue due to a non-existing key in the following line: `{slaap}` laat Hedy voor een (paar) seconde(n) pauzeren. There is an issue due to a non-existing key in the following line: `{Add}` iets `{to_list}` een lijst. There is an issue due to an empty placeholder in the following line: We kunnen dus een `{while}` loop gebruiken met `{!=}`.
Ah good catch!! We are only seeing this now on main since we run the generation on commit since #3333! I agree this should be a failing test instead of an output! We can either copy this code to the unit tests (more clear but a bit more work) or maybe just throw an
assert
in the generation instead of a
I will look into adding this to the unit tests. Downside is that it will even further increase the time it takes to run these.
I will look into adding this to the unit tests.
Thanks!!
Downside is that it will even further increase the time it takes to run these.
Yeah that is true but incorrect example code is shitty for students too!
https://github.com/Felienne/hedy/pull/3358 fixes the concrete issues mentioned here, but I rewrite this issue to write tests so this cannot occur again
yaml-validator now does this!