This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
yap-6.3/regression/modules/goal_expansion_tests.yap
Vitor Santos Costa cc6eca6903 jupyter
2018-03-17 10:38:56 +00:00

16 lines
421 B
Prolog

:- use_module(library(lists)).
test a(X) returns atom(X) .+
given user:goal_expansion(a(X), current_atom(X))
test m:a(3,X) returns X =@= 15,
given user:goal_expansion(a(X,Y), Y is X*5)
test m:a(3,X) returns X =@= 9
given user:goal_expansion(a(X,Y), m, Y is X*X ))
test m:a(3,X) returns X =@= 9
given user:goal_expansion(a(X,Y), m, Y is X*X ), user:goal_expansion(a(X), X is 3*5)