-
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
Erik Lieben
authored
Dec 29, 2017
1 parent
b143ce8
commit 5bcdfce
Showing
2 changed files
with
59 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { assert } from 'chai'; | ||
import { getTokenOnCharRange, hasScope, tokenizeLine } from './test.utils'; | ||
|
||
describe('The Aurelia HTML syntax let element', () => { | ||
|
||
it('must tokenize let start element with scope "let.element.html.au"', () => { | ||
|
||
// arrange | ||
let scope = 'let.element.html.au'; | ||
|
||
// act | ||
let lineToken = tokenizeLine('<let>'); | ||
|
||
// assert | ||
let token = getTokenOnCharRange(lineToken, 1, 4); | ||
assert.isOk(hasScope(token.scopes, scope)); | ||
|
||
}); | ||
|
||
it('must tokenize let end element with scope "let.element.html.au"', () => { | ||
|
||
// arrange | ||
let scope = 'let.element.html.au'; | ||
|
||
// act | ||
let lineToken = tokenizeLine('</let>'); | ||
|
||
// assert | ||
let token = getTokenOnCharRange(lineToken, 2, 5); | ||
assert.isOk(hasScope(token.scopes, scope)); | ||
|
||
}); | ||
|
||
}); |