You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original bug ID: 6840 Reporter:@lpw25 Assigned to:@gasche Status: closed (set by @xavierleroy on 2016-12-07T10:48:57Z) Resolution: fixed Priority: normal Severity: minor Fixed in version: 4.02.2+dev / +rc1 Category: configure and build/install
Bug description
The test in testsuite/tests/utils/edit_distance.ml always fails if you have not
run make world.opt. The attached patch fixes this by only running the test in
bytecode mode.
It should be noted that this test is a unit test of a function within the
compiler. This is inconsistent with the rest of the testsuite, and it should
probably be replace by a test which checks the actual output of the compiler.
I suggest merging the attached fix, but leaving the bug unresolved until the test
has been rewritten.
This is inconsistent with the rest of the testsuite, and it should
probably be replace by a test which checks the actual output of the compiler.
What would be the point of such a change? My idea in adding the test is that we might want to change the implementation (eg. to a more optimized one) later, and that this testcase could catch regression bugs at this time. Trying to test the compiler output seems harder, more fragile (you're sensitive to changes in heuristics), and likely to catch less bugs.
I guess it is just quite strange to have a single unit test in amongst all the non-unit tests. Every other test tests the behaviour of the compiler that has been built, whereas this test compiles some new code and tests the behaviour of that.
Perhaps it would make more sense if this test was testing the behaviour of the function within the appropriate compiler-libs. I know it wouldn't make much difference, but at least then it would be testing an output of the build process rather than testing the source directly.
I applied the patch you propose (BYTECODE_ONLY). Given that the rest of the suggestion seems hard to implement without weakening the safety guarantees, I'm fine with "strange" here and mark the bug resolved (but do feel free to complain here if the odd test does create another actual problem someday).
Original bug ID: 6840
Reporter: @lpw25
Assigned to: @gasche
Status: closed (set by @xavierleroy on 2016-12-07T10:48:57Z)
Resolution: fixed
Priority: normal
Severity: minor
Fixed in version: 4.02.2+dev / +rc1
Category: configure and build/install
Bug description
The test in testsuite/tests/utils/edit_distance.ml always fails if you have not
run
make world.opt
. The attached patch fixes this by only running the test inbytecode mode.
It should be noted that this test is a unit test of a function within the
compiler. This is inconsistent with the rest of the testsuite, and it should
probably be replace by a test which checks the actual output of the compiler.
I suggest merging the attached fix, but leaving the bug unresolved until the test
has been rewritten.
File attachments
The text was updated successfully, but these errors were encountered: