Commit Graph

4 Commits

Author SHA1 Message Date
Zoltan Somogyi
d23c4f74a3 Update the style of more tests. 2020-10-06 19:20:18 +11:00
Zoltan Somogyi
33eb3028f5 Clean up the tests in half the test directories.
tests/accumulator/*.m:
tests/analysis_*/*.m:
tests/benchmarks*/*.m:
tests/debugger*/*.{m,exp,inp}:
tests/declarative_debugger*/*.{m,exp,inp}:
tests/dppd*/*.m:
tests/exceptions*/*.m:
tests/general*/*.m:
tests/grade_subdirs*/*.m:
tests/hard_coded*/*.m:
    Make these tests use four-space indentation, and ensure that
    each module is imported on its own line. (I intend to use the latter
    to figure out which subdirectories' tests can be executed in parallel.)

    These changes usually move code to different lines. For the debugger tests,
    specify the new line numbers in .inp files and expect them in .exp files.
2015-02-14 20:14:03 +11:00
Julien Fischer
266c1fac41 Fix a bug reported by Tomas By on mercury-bugs: the behaviour of
Branches: main, 11.07

Fix a bug reported by Tomas By on mercury-bugs: the behaviour of
multi_map.det_update/4 did not match the documentation.

library/multi_map.m:
	Fix the behaviour of det_update/4.

	Add replace/4, a semidet version of det_replace/4.

	Reformat some documentation.

NEWS:
	Announce the above fix and addition.

tests/hard_coded/multi_map_test.{m,exp}:
	Replace the existing test for multi_maps with something a bit
	stronger: in particular check the semantics of update, replace,
	insert and set.
2011-07-12 07:11:06 +00:00
Mark Brown
88940110b7 Fix multi_map__from_corresponding_lists so that it works as
Estimated hours taken: 0.25
Branches: main, release

library/multi_map.m:
	Fix multi_map__from_corresponding_lists so that it works as
	expected if a key appears more than once in the key list.

tests/hard_coded/Mmakefile:
tests/hard_coded/multi_map_test.exp:
tests/hard_coded/multi_map_test.m:
	Test case.
2002-08-20 00:44:20 +00:00