diff --git a/snippets/expect.snippet b/snippets/expect.snippet new file mode 100644 index 0000000..858e104 --- /dev/null +++ b/snippets/expect.snippet @@ -0,0 +1 @@ +expect( ${1} ).to${2}(); diff --git a/snippets/spy.snippet b/snippets/spy.snippet new file mode 100644 index 0000000..6c13f63 --- /dev/null +++ b/snippets/spy.snippet @@ -0,0 +1 @@ +spyOn( ${1:object}, '${2:method}' ); diff --git a/syntax/jasmine.vim b/syntax/jasmine.vim index 097d1de..112164c 100644 --- a/syntax/jasmine.vim +++ b/syntax/jasmine.vim @@ -6,9 +6,17 @@ runtime! syntax/javascript.vim syn case match syn keyword specFunctions afterEach beforeEach describe it expect addMatchers spyOn not +syn keyword specDisabled xit xdescribe +syn keyword specSpys andCallThrough andReturn andThrow andCallFake callCount argsForCall mostRecentCall +syn keyword specAsync runs waits waitsFor syn match specMatcher "to[A-Za-z0-9_]*" +syn keyword specjQuery loadFixtures readFixtures setFixtures sandbox clearCache cleanUp hi def link specFunctions Special +hi def link specDisabled Error hi def link specMatcher Special +hi def link specSpys Special +hi def link specAsync Special +hi def link specjQuery Special let b:current_syntax = "jasmine"