Added tests.

This commit is contained in:
Daniel Rosenwasser 2014-12-03 15:05:38 -08:00
parent d4575572b6
commit 0e9561194b
2 changed files with 27 additions and 0 deletions

View File

@ -0,0 +1,16 @@
////export function
/////**
//// * This is a class.
//// */
////{| "itemName": "C", "kind": "class" |} class C {
//// {| "itemName": "foo", "kind": "method" |} foo() {
//// }
////}
test.markers().forEach((marker) => {
verify.getScriptLexicalStructureListContains(marker.data.itemName, marker.data.kind, marker.fileName, marker.data.parentName);
});
/// Only have two named elements.
verify.getScriptLexicalStructureListCount(2);

View File

@ -0,0 +1,11 @@
/////**
//// * This is a class.
//// */
////class /* But it has no name! */ {
//// foo() {
//// }
////}
// The class is unnamed, so its method is not included either.
verify.getScriptLexicalStructureListCount(0);