Commit Graph

25 Commits

Author SHA1 Message Date
Bennet Bleßmann
d907f86c8d use call_with_error_context 2025-08-01 20:49:43 +02:00
Bennet Bleßmann
fadd3a0839 use named vars instead of wildcards
makes updating tests easier as globs are sometimes lost when using TRYCMD=overwrite
2025-08-01 20:49:35 +02:00
Bennet Bleßmann
45041be336 fix culprit 2025-08-01 20:49:24 +02:00
Bennet Bleßmann
b2d639b159 fix arity of prcess_wait builtin errors 2025-08-01 20:49:14 +02:00
Bennet Bleßmann
3a6b92d227 more tests 2025-08-01 20:49:03 +02:00
Bennet Bleßmann
143f32be23 adjust options checking and add more tests 2025-08-01 20:48:44 +02:00
Mark Thom
c77ea48fbd Merge pull request #2804 from dnmfarrell/line-count-off-by-one
Line numbers start at 1
2025-02-12 23:23:44 -08:00
Emilie Burgun
2a218f34b9 Test corner cases of stream aliasing 2025-02-06 23:47:22 +01:00
David Farrell
f509d3d66f Line numbers start at 1
Bumps the line number for the singleton warning. When the singleton
occurs on the same line at the term starts, the line number is correct:

    foo(X).

However it stills mis-reports this line number as 1 instead of 5:

    foo(1) :-
        true,
        true,
        true,
        Y.

See issue #1356.
2025-02-02 08:16:05 -05:00
Mark Thom
5a869e8b48 Merge pull request #2777 from adri326/fix-2772-rnd_i-clipping
Fix invalid casts in is/2
2025-01-26 23:14:57 -07:00
Emilie Burgun
0cde8f9a43 Add integration tests for arithmetic operators
This extensively tests the behavior of is/2, both when compiled and in metacalls.
2025-01-27 00:10:56 +01:00
Emilie Burgun
b76bdd75e4 Fix #2725 by calling load_context/1 in the unspecified branch of strip_module/3
This fixes #2725, by making it so that `strip_module(Pred, M, P), call(M:P)`
doesn't throw an `instanciation_error` when `Pred` isn't in the form `module:predicate`.

Now, `strip_module(hello, M, P)` will call `load_context(M)`, which unifies `M`
with the topmost module (or `user`).

Two new test cases are added: issue2725.pl, which tests the minimal case id(X) --> X.
and the strip_module(P, M, _), call(M:P) scenario, and module_resolution,
which tests the behavior of strip_module in a few scenarios.
2025-01-12 14:08:28 +01:00
Bennet Bleßmann
c24a51b633 fix looping from issue 2467 2024-08-17 23:37:12 +02:00
Bennet Bleßmann
058b9c5e51 switch invalid term from type to domain error 2024-08-05 21:25:44 +02:00
Bennet Bleßmann
5a0abd713e change declaration to directive 2024-08-05 21:25:43 +02:00
Bennet Bleßmann
df33da111e ajust/add devlaration errors to be more standard compliant 2024-08-05 21:25:43 +02:00
Bennet Bleßmann
880e22d164 adjust errors to be more standard compliant 2024-08-05 21:25:42 +02:00
Bennet Bleßmann
59af900aaf split up CompilationError::InconsistentEntry 2024-08-05 21:25:42 +02:00
Bennet Bleßmann
add03cb4ee add test for declaration errors 2024-08-05 21:25:42 +02:00
Mark Thom
9837187183 add nth_partial_strings_tests for bugs raised in #1827, #2381 2024-04-10 15:50:24 -06:00
Mark Thom
c2657cce37 use common test_framework module for several test suites 2024-04-10 15:47:31 -06:00
Adrián Arroyo Calle
ec4a8745e7 Add all_mdoules test and fix library(csv) 2024-02-04 21:34:01 +01:00
bakaq
f411fb1eb3 Tests for when/2 and solved bug 2023-12-11 12:28:59 -03:00
Skgland
57b52fbe90 fix windows test by not disabling normalization
- this re-enables line ending and file path normalization
  - the latter might be unwanted, but there is only a shared flag
  - this might result in too loose matching of / and \ in stdout and stderr as prolog syntax may be mistaken for a path
2023-12-04 22:59:52 +01:00
Skgland
1c52de9ab1 File-oriented testing
inspired by #2191 but for the `run_top_level_test_with_args`s and  `run_top_level_test_no_args instead of the `load_module_test`s
2023-12-04 22:02:46 +01:00