vim-flavor 1.1.3 → 1.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +2 -2
- data/features/flavorfile/version_constraint.feature +1 -1
- data/features/philosophy.md +1 -1
- data/features/testing_vim_plugins/specifying_test_scripts.feature +49 -4
- data/lib/vim-flavor/facade.rb +16 -6
- data/lib/vim-flavor/version.rb +1 -1
- metadata +21 -33
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 9a818d197eec161218d1c58cd0fd414a3938c7db
|
4
|
+
data.tar.gz: c2afd93c592d5944354ed61e1a8cf8b7abd756bc
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: ba27a0c96e51e0fe5b98d68e8ef493632dcbc48f95555bdaa390bc0aaa3ca197c8830d054cd6d0334e56d490b2a04f13283f0e358a3cff74f50ed75f37a49f7b
|
7
|
+
data.tar.gz: afcb9952d6fb377449a6a634d758bacf1118ebdec02b806ea85479ab310643ea99f27c1104baa99c94ec5bd4cbe96691fb6a8374cbcf9e0f1b4c7e4daee8b516
|
data/LICENSE
CHANGED
@@ -3,7 +3,7 @@ Feature: Version constraint
|
|
3
3
|
as a lazy Vim user,
|
4
4
|
I want to declare desirable versions of Vim plugins.
|
5
5
|
|
6
|
-
Note that vim-flavor assumes that plugins follow [the versioning
|
6
|
+
Note that vim-flavor assumes that plugins follow [the versioning policies of
|
7
7
|
RubyGems](http://docs.rubygems.org/read/chapter/7#page26), to determine
|
8
8
|
compatibility of plugins. See also [Philosophy](../philosophy) for the
|
9
9
|
details.
|
data/features/philosophy.md
CHANGED
@@ -11,7 +11,7 @@ vim-flavor can install plugins which meet the following conditions:
|
|
11
11
|
[plugins uploaded to www.vim.org](http://www.vim.org/scripts/index.php).
|
12
12
|
* Experimental plugins which are not uploaded to www.vim.org
|
13
13
|
are usually found in [GitHub](https://github.com/).
|
14
|
-
* Plugins must follow [the versioning
|
14
|
+
* Plugins must follow [the versioning policies of
|
15
15
|
RubyGems](http://docs.rubygems.org/read/chapter/7#page26) and have "version"
|
16
16
|
tags in their repositories. For example, if there is the version 1.2.3 of
|
17
17
|
a plugin, its repository must have the tag `1.2.3`, and the files of the
|
@@ -1,14 +1,13 @@
|
|
1
1
|
Feature: Specifying test scripts
|
2
|
-
In order to run test scripts not in the standard `t` directory
|
2
|
+
In order to run test scripts not in the standard `t` directory
|
3
|
+
or to run specific test scripts,
|
3
4
|
As a lazy Vim user,
|
4
5
|
I want to specify test scripts to be run,
|
5
6
|
like `vim-flavor test FILES-OR-DIRECTOREIS`.
|
6
7
|
|
7
8
|
Background:
|
8
9
|
Given a repository "kana/vim-vspec" from offline cache
|
9
|
-
|
10
|
-
Scenario: Running test scripts in non-standard location
|
11
|
-
Given a flavorfile with:
|
10
|
+
And a flavorfile with:
|
12
11
|
"""ruby
|
13
12
|
# No dependency
|
14
13
|
"""
|
@@ -31,6 +30,8 @@ Feature: Specifying test scripts
|
|
31
30
|
echo 'ok 1'
|
32
31
|
echo '1..1'
|
33
32
|
"""
|
33
|
+
|
34
|
+
Scenario: Running test scripts in non-standard location
|
34
35
|
When I run `vim-flavor test spec`
|
35
36
|
Then it should pass with regexp:
|
36
37
|
"""
|
@@ -55,3 +56,47 @@ Feature: Specifying test scripts
|
|
55
56
|
kana/vim-vspec \(1\.\d+(\.\d+)?\)
|
56
57
|
"""
|
57
58
|
And a dependency "kana/vim-vspec" is stored in ".vim-flavor/deps"
|
59
|
+
|
60
|
+
Scenario: Running a specific `.vim` test script
|
61
|
+
When I run `vim-flavor test spec/basics.vim`
|
62
|
+
Then it should pass with regexp:
|
63
|
+
"""
|
64
|
+
-------- Preparing dependencies
|
65
|
+
Checking versions...
|
66
|
+
Use kana/vim-vspec ... 1\.\d+(\.\d+)?
|
67
|
+
Deploying plugins...
|
68
|
+
kana/vim-vspec 1\.\d+(\.\d+)? ... done
|
69
|
+
Completed.
|
70
|
+
-------- Testing a Vim plugin
|
71
|
+
spec/basics.vim .. ok
|
72
|
+
All tests successful.
|
73
|
+
Files=1, Tests=1, \d+ wallclock secs .*
|
74
|
+
Result: PASS
|
75
|
+
"""
|
76
|
+
And a lockfile is created and matches with:
|
77
|
+
"""
|
78
|
+
kana/vim-vspec \(1\.\d+(\.\d+)?\)
|
79
|
+
"""
|
80
|
+
And a dependency "kana/vim-vspec" is stored in ".vim-flavor/deps"
|
81
|
+
|
82
|
+
Scenario: Running a specific `.t` test script
|
83
|
+
When I run `vim-flavor test spec/sh.t`
|
84
|
+
Then it should pass with regexp:
|
85
|
+
"""
|
86
|
+
-------- Preparing dependencies
|
87
|
+
Checking versions...
|
88
|
+
Use kana/vim-vspec ... 1\.\d+(\.\d+)?
|
89
|
+
Deploying plugins...
|
90
|
+
kana/vim-vspec 1\.\d+(\.\d+)? ... done
|
91
|
+
Completed.
|
92
|
+
-------- Testing a Vim plugin
|
93
|
+
spec/sh.t .. ok
|
94
|
+
All tests successful.
|
95
|
+
Files=1, Tests=1, \d+ wallclock secs .*
|
96
|
+
Result: PASS
|
97
|
+
"""
|
98
|
+
And a lockfile is created and matches with:
|
99
|
+
"""
|
100
|
+
kana/vim-vspec \(1\.\d+(\.\d+)?\)
|
101
|
+
"""
|
102
|
+
And a dependency "kana/vim-vspec" is stored in ".vim-flavor/deps"
|
data/lib/vim-flavor/facade.rb
CHANGED
@@ -36,12 +36,22 @@ module Vim
|
|
36
36
|
plugin_paths = lockfile.flavors.map {|f|
|
37
37
|
"#{deps_path}/#{f.repo_name.zap}"
|
38
38
|
}
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
39
|
+
dirs = files_or_dirs.select {|p| File.directory?(p)}
|
40
|
+
t_files = files_or_dirs.select {|p| File.file?(p) &&
|
41
|
+
File.extname(p) == '.t'}
|
42
|
+
vim_files = files_or_dirs.select {|p| File.file?(p) &&
|
43
|
+
File.extname(p) == '.vim'}
|
44
|
+
commands = []
|
45
|
+
commands <<
|
46
|
+
%Q{ prove --ext '.t' #{prove_options} \
|
47
|
+
#{(dirs + t_files).shelljoin} } if files_or_dirs.none? or
|
48
|
+
dirs.any? or t_files.any?
|
49
|
+
commands <<
|
50
|
+
%Q{ prove --ext '.vim' #{prove_options} \
|
51
|
+
--exec '#{vspec} #{Dir.getwd()} #{plugin_paths.join(' ')}' \
|
52
|
+
#{(dirs + vim_files).shelljoin} } if files_or_dirs.none? or
|
53
|
+
dirs.any? or vim_files.any?
|
54
|
+
succeeded = system(commands.join('&&'))
|
45
55
|
exit(1) unless succeeded
|
46
56
|
end
|
47
57
|
|
data/lib/vim-flavor/version.rb
CHANGED
metadata
CHANGED
@@ -1,94 +1,83 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vim-flavor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
5
|
-
prerelease:
|
4
|
+
version: 1.1.4
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Kana Natsuno
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2014-02-09 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: parslet
|
16
15
|
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
16
|
requirements:
|
19
|
-
- - ~>
|
17
|
+
- - "~>"
|
20
18
|
- !ruby/object:Gem::Version
|
21
19
|
version: '1.0'
|
22
20
|
type: :runtime
|
23
21
|
prerelease: false
|
24
22
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
23
|
requirements:
|
27
|
-
- - ~>
|
24
|
+
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
26
|
version: '1.0'
|
30
27
|
- !ruby/object:Gem::Dependency
|
31
28
|
name: thor
|
32
29
|
requirement: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
30
|
requirements:
|
35
|
-
- - ~>
|
31
|
+
- - "~>"
|
36
32
|
- !ruby/object:Gem::Version
|
37
33
|
version: '0.14'
|
38
34
|
type: :runtime
|
39
35
|
prerelease: false
|
40
36
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
-
none: false
|
42
37
|
requirements:
|
43
|
-
- - ~>
|
38
|
+
- - "~>"
|
44
39
|
- !ruby/object:Gem::Version
|
45
40
|
version: '0.14'
|
46
41
|
- !ruby/object:Gem::Dependency
|
47
42
|
name: aruba
|
48
43
|
requirement: !ruby/object:Gem::Requirement
|
49
|
-
none: false
|
50
44
|
requirements:
|
51
|
-
- - ~>
|
45
|
+
- - "~>"
|
52
46
|
- !ruby/object:Gem::Version
|
53
47
|
version: '0.5'
|
54
48
|
type: :development
|
55
49
|
prerelease: false
|
56
50
|
version_requirements: !ruby/object:Gem::Requirement
|
57
|
-
none: false
|
58
51
|
requirements:
|
59
|
-
- - ~>
|
52
|
+
- - "~>"
|
60
53
|
- !ruby/object:Gem::Version
|
61
54
|
version: '0.5'
|
62
55
|
- !ruby/object:Gem::Dependency
|
63
56
|
name: cucumber
|
64
57
|
requirement: !ruby/object:Gem::Requirement
|
65
|
-
none: false
|
66
58
|
requirements:
|
67
|
-
- - ~>
|
59
|
+
- - "~>"
|
68
60
|
- !ruby/object:Gem::Version
|
69
61
|
version: '1.2'
|
70
62
|
type: :development
|
71
63
|
prerelease: false
|
72
64
|
version_requirements: !ruby/object:Gem::Requirement
|
73
|
-
none: false
|
74
65
|
requirements:
|
75
|
-
- - ~>
|
66
|
+
- - "~>"
|
76
67
|
- !ruby/object:Gem::Version
|
77
68
|
version: '1.2'
|
78
69
|
- !ruby/object:Gem::Dependency
|
79
70
|
name: rspec
|
80
71
|
requirement: !ruby/object:Gem::Requirement
|
81
|
-
none: false
|
82
72
|
requirements:
|
83
|
-
- - ~>
|
73
|
+
- - "~>"
|
84
74
|
- !ruby/object:Gem::Version
|
85
75
|
version: '2.8'
|
86
76
|
type: :development
|
87
77
|
prerelease: false
|
88
78
|
version_requirements: !ruby/object:Gem::Requirement
|
89
|
-
none: false
|
90
79
|
requirements:
|
91
|
-
- - ~>
|
80
|
+
- - "~>"
|
92
81
|
- !ruby/object:Gem::Version
|
93
82
|
version: '2.8'
|
94
83
|
description: A tool to manage your favorite Vim plugins
|
@@ -99,10 +88,10 @@ executables:
|
|
99
88
|
extensions: []
|
100
89
|
extra_rdoc_files: []
|
101
90
|
files:
|
102
|
-
- .gitignore
|
103
|
-
- .gitmodules
|
104
|
-
- .rspec
|
105
|
-
- .travis.yml
|
91
|
+
- ".gitignore"
|
92
|
+
- ".gitmodules"
|
93
|
+
- ".rspec"
|
94
|
+
- ".travis.yml"
|
106
95
|
- Gemfile
|
107
96
|
- LICENSE
|
108
97
|
- README.md
|
@@ -174,27 +163,26 @@ files:
|
|
174
163
|
- vim-flavor.gemspec
|
175
164
|
homepage: https://github.com/kana/vim-flavor
|
176
165
|
licenses: []
|
166
|
+
metadata: {}
|
177
167
|
post_install_message:
|
178
168
|
rdoc_options: []
|
179
169
|
require_paths:
|
180
170
|
- lib
|
181
171
|
required_ruby_version: !ruby/object:Gem::Requirement
|
182
|
-
none: false
|
183
172
|
requirements:
|
184
|
-
- -
|
173
|
+
- - ">="
|
185
174
|
- !ruby/object:Gem::Version
|
186
175
|
version: '0'
|
187
176
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
188
|
-
none: false
|
189
177
|
requirements:
|
190
|
-
- -
|
178
|
+
- - ">="
|
191
179
|
- !ruby/object:Gem::Version
|
192
180
|
version: '0'
|
193
181
|
requirements: []
|
194
182
|
rubyforge_project:
|
195
|
-
rubygems_version:
|
183
|
+
rubygems_version: 2.2.1
|
196
184
|
signing_key:
|
197
|
-
specification_version:
|
185
|
+
specification_version: 4
|
198
186
|
summary: A tool to manage your favorite Vim plugins
|
199
187
|
test_files:
|
200
188
|
- features/README.md
|