-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature insert code eating features? #724
Comments
Only the new features are returned from writeFeatures method |
Ah, OK, so the tests have an assumption that new things are added to the end of the file. My thought was to place all the definitions right at the top. Anyway, that makes more sense; thank you! |
it's defined in ufo2ft/tests/featureWriters/__init__.py Lines 9 to 20 in 87c6881
however, now I'm thinking that assuming that only the lines following len(feaFile) are new might not actually be true all the time esp. with insertion markers and such |
I'm rewriting it to look for "really new" statements (i.e. not in the file before), regardless of where they were. This will allow me to then put definitions at the top. |
I just started trying to fix #506 (at least the part where abvm/blwm/mark are having classes placed in the wrong order), and I noticed something odd in my test failures:
Wait, what, is the kern feature writer hallucinating entire features? No, it turns out that we add that code to the feature file when testing:
ufo2ft/tests/featureWriters/kernFeatureWriter_test.py
Lines 1380 to 1392 in 87c6881
but when we set our test expectations, it's not there:
ufo2ft/tests/featureWriters/kernFeatureWriter_test.py
Lines 1326 to 1335 in 87c6881
I don't understand this. To me it looks like the kern feature writer is eating the ss01 feature, and our tests ensure that it does get eaten. Am I reading this wrong?
The text was updated successfully, but these errors were encountered: