Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
[fix] Stop the kobo_touch_probe test from causing problems for other tests. #3877
Previously, it caused problems because it was overriding
tl;dr: this is an example of one test affecting another negatively, and I tried other ways to fix it too, but at least this way seems to work. I tried to explain the underlying problem and my reasoning below.
This one took me a little while, not just to isolate where and figure out what was going on, but also to fix, as there's apparently some magic in there that was working against me. (It doesn't really help that I'm pretty much learning Lua as I go along here, as well as the Koreader codebase...)
The whole thing started with me being annoyed by and wanting to fix a failure I was seeing in the translator test, figuring that the test probably wasn't cleaning up after itself or something like that (since it didn't fail on the first run, only from the second). That wasn't actually the case though - or rather, only sort of, and not that test's fault. It is actually removing again the setting it adds. However, the touch-probe test caused it to use the wrong settings file, as the test harness uses a different file than the tool does, and although the harness removes that settings file, it doesn't remove the
I first tried fixing this in the probe test itself, by saving
There's at least one test around here with the opposite problem: it breaks in isolation (or if not in the "right" order). See 5bd288e. I haven't found the time to look at it, but it should be fixed sometime.
I wrote that language spec, but I don't think I ever looked at the touch probe spec. Thanks for finding a solution. :-)