Skip to main content

module examples::fixedMembers::Test

rascal-0.34.0
typepal-0.8.10

Usage

import examples::fixedMembers::Test;

Source code

http://github.com/usethesource/typepal/src/examples/fixedMembers/Test.rsc

Dependencies

import examples::fixedMembers::Syntax;
extend examples::fixedMembers::Checker;
extend analysis::typepal::TestFramework;
import ParseTree;

function fixedMembersTModelForTree

TModel fixedMembersTModelForTree(Tree pt){
return collectAndSolve(pt, config = fixedMembersConfig());
}

function fixedMembersTModelFromName

TModel fixedMembersTModelFromName(str mname){
pt = parse(#start[Program], |project://typepal/src/examples/fixedMembers/<mname>.alias|).top;
return fixedMembersTModelForTree(pt);
}

function main

bool main() = fixedMembersTests();

Tests

test fixedMembersTests

test bool fixedMembersTests() {
return runTests([|project://typepal/src/examples/fixedMembers/fixedMembers.ttl|],
#start[Program],
TModel (Tree t) { return fixedMembersTModelForTree(t); },
runName = "fixedMembers");
}