aruba 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/History.txt +3 -0
- data/Rakefile +1 -1
- data/aruba.gemspec +1 -1
- data/features/file_system_commands.feature +14 -1
- data/lib/aruba/api.rb +6 -0
- data/lib/aruba/cucumber.rb +4 -0
- metadata +2 -2
data/History.txt
CHANGED
data/Rakefile
CHANGED
data/aruba.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{aruba}
|
8
|
-
s.version = "0.1.
|
8
|
+
s.version = "0.1.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Aslak Helles\303\270y", "David Chelimsky"]
|
@@ -9,7 +9,7 @@ Feature: file system commands
|
|
9
9
|
When I run "ruby -e \"puts test ?d, 'foo'\""
|
10
10
|
Then the stdout should contain "true"
|
11
11
|
|
12
|
-
Scenario:
|
12
|
+
Scenario: create a file
|
13
13
|
Given a file named "foo/bar/example.rb" with:
|
14
14
|
"""
|
15
15
|
puts "hello world"
|
@@ -17,6 +17,19 @@ Feature: file system commands
|
|
17
17
|
When I run "ruby foo/bar/example.rb"
|
18
18
|
Then I should see "hello world"
|
19
19
|
|
20
|
+
Scenario: append to a file
|
21
|
+
Given a file named "foo/bar/example.rb" with:
|
22
|
+
"""
|
23
|
+
puts "hello world"
|
24
|
+
"""
|
25
|
+
When I append to "foo/bar/example.rb" with:
|
26
|
+
"""
|
27
|
+
puts "this was appended"
|
28
|
+
"""
|
29
|
+
When I run "ruby foo/bar/example.rb"
|
30
|
+
Then I should see "hello world"
|
31
|
+
And I should see "this was appended"
|
32
|
+
|
20
33
|
Scenario: clean up files generated in previous scenario
|
21
34
|
When I run "ruby foo/bar/example.rb"
|
22
35
|
Then the exit status should be 1
|
data/lib/aruba/api.rb
CHANGED
data/lib/aruba/cucumber.rb
CHANGED
@@ -14,6 +14,10 @@ Given /^a file named "([^\"]*)" with:$/ do |file_name, file_content|
|
|
14
14
|
create_file(file_name, file_content)
|
15
15
|
end
|
16
16
|
|
17
|
+
When /^I append to "([^\"]*)" with:$/ do |file_name, file_content|
|
18
|
+
append_to_file(file_name, file_content)
|
19
|
+
end
|
20
|
+
|
17
21
|
When /^I cd to "([^\"]*)"$/ do |dir|
|
18
22
|
cd(dir)
|
19
23
|
end
|