forked from vim-test/vim-test
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpest_spec.vim
57 lines (39 loc) · 1.05 KB
/
pest_spec.vim
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
source spec/support/helpers.vim
describe "Pest"
before
cd spec/fixtures/pest
end
after
call Teardown()
cd -
end
it "runs file tests"
view PestTest.php
TestFile
Expect g:test#last_command == 'pest --colors PestTest.php'
end
it "runs nearest tests"
view +1 PestTest.php
TestNearest
Expect g:test#last_command == "pest --colors PestTest.php"
view +4 PestTest.php
TestNearest
Expect g:test#last_command == "pest --colors --filter 'is a test case' PestTest.php"
view +8 PestTest.php
TestNearest
Expect g:test#last_command == "pest --colors --filter 'with a different descriptor' PestTest.php"
view +12 PestTest.php
TestNearest
Expect g:test#last_command == "pest --colors --filter 'bdd flavour' PestTest.php"
end
it "runs test suites"
view PestTest.php
TestSuite
Expect g:test#last_command == 'pest --colors'
end
it "doesn't recognize files that don't end with 'Test'"
view normal.php
TestFile
Expect exists('g:test#last_command') == 0
end
end