module examples::structParameters::Test
rascal-0.40.16
typepal-0.14.8
Usage
import examples::structParameters::Test;
Source code
http://github.com/usethesource/typepal/src/examples/structParameters/Test.rsc
Dependencies
import examples::structParameters::Syntax;
extend examples::structParameters::Checker;
extend analysis::typepal::TestFramework;
import ParseTree;
function structParametersTModelForTree
TModel structParametersTModelForTree(Tree pt){
return collectAndSolve(pt, config = structParametersConfig(), modelName="struct-parameters");
}
function structParametersTModelFromName
TModel structParametersTModelFromName(str mname){
pt = parse(#start[Program], |project://typepal/src/examples/structParameters/<mname>.struct|).top;
return structParametersTModelForTree(pt);
}
function main
value main()
= structParametersTests();
Tests
test structParametersTests
test bool structParametersTests() {
return runTests([|project://typepal/src/examples/structParameters/tests.ttl|],
#start[Program],
TModel (Tree t) { return structParametersTModelForTree(t); },
runName = "StructParameters");
}