Skip to content

Commit

Permalink
Add syntax tests for curly bracketed terms to Prolog compliance suite
Browse files Browse the repository at this point in the history
  • Loading branch information
pmoura committed Jun 30, 2018
1 parent 0126aa8 commit 1acf990
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
4 changes: 2 additions & 2 deletions RELEASE_NOTES.md
Expand Up @@ -37,8 +37,8 @@ and are equivalent to a sequence of `context/1` and `throw/1` method calls.
Tests
-----

* ADDED: Tests for syntax errors in atoms, lists, and numbers to the Prolog
compliance suite.
* ADDED: Tests for syntax errors in atoms, lists, numbers, and curly bracketed
terms to the Prolog compliance suite.

Examples
--------
Expand Down
14 changes: 12 additions & 2 deletions tests/prolog/syntax/curly_terms/tests.lgt
Expand Up @@ -22,9 +22,9 @@
extends(lgtunit)).

:- info([
version is 1.0,
version is 1.1,
author is 'Paulo Moura',
date is 2014/11/07,
date is 2018/06/30,
comment is 'Unit tests for the ISO Prolog standard curly bracketed term syntax.'
]).

Expand All @@ -40,6 +40,16 @@
{read(T)},
T == '{}'(','(a,b)).

succeeds(lgt_curly_bracketed_term_03) :-
^^set_text_input('{}. '),
{read(T)},
T = '{}'.

succeeds(lgt_curly_bracketed_term_04) :-
^^set_text_input('{(a,b)}. '),
{read(T)},
T == '{}'(','(a,b)).

cleanup :-
^^clean_text_input.

Expand Down

0 comments on commit 1acf990

Please sign in to comment.