infrataster 0.1.12 → 0.1.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/lib/infrataster/rspec.rb +3 -0
- data/lib/infrataster/version.rb +1 -1
- data/spec/integration/other_spec.rb +8 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 944bd475f663cf33b6920d7f6d24f371c02c07a2
|
4
|
+
data.tar.gz: 326662ce5da70920bff0133d5bf915eeb4ee20b6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4d57ca47020df771a887b5e94828f27821515013d3423aa0ef25d925e0f38b43762a39ce84778f86a1b805ae3cd5706dd9d4ec44e03992547bab36de05f83b92
|
7
|
+
data.tar.gz: e9fd30168998cd809bd45d63a4440796bdbfa82ff8b08cc7d97ae516556eea5a6b9fd3055372096ad4a647e9e019512f8015826406da6a52f680539de1ba9af6
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,14 @@
|
|
1
1
|
# Infrataster Changelog
|
2
|
+
## v0.1.13
|
3
|
+
|
4
|
+
* Make Infrataster's methods available in before(:all) block. (by @KitaitiMakoto)
|
5
|
+
|
6
|
+
## v0.1.12
|
7
|
+
|
8
|
+
* Add infrataster command to create template directory.
|
9
|
+
* Specify host in a option passed to Server.define. (by @KitaitiMakoto)
|
10
|
+
* Add Server#ssh method. (by @KitaitiMakoto)
|
11
|
+
|
2
12
|
## v0.1.11
|
3
13
|
|
4
14
|
* Slight bug fixes
|
data/lib/infrataster/rspec.rb
CHANGED
@@ -6,6 +6,9 @@ include Infrataster::Helpers::ResourceHelper
|
|
6
6
|
RSpec.configure do |config|
|
7
7
|
config.include Infrataster::Helpers::RSpecHelper
|
8
8
|
|
9
|
+
config.before(:all) do
|
10
|
+
@infrataster_context = Infrataster::Contexts.from_example(self.class)
|
11
|
+
end
|
9
12
|
config.before(:each) do
|
10
13
|
@infrataster_context = Infrataster::Contexts.from_example(example)
|
11
14
|
@infrataster_context.before_each(example) if @infrataster_context.respond_to?(:before_each)
|
data/lib/infrataster/version.rb
CHANGED
@@ -8,6 +8,10 @@ end
|
|
8
8
|
|
9
9
|
describe server(:proxy) do
|
10
10
|
let(:time) { Time.now }
|
11
|
+
before :all do
|
12
|
+
@before_all_time = Time.now
|
13
|
+
current_server.ssh_exec "echo 'Hello once' > /tmp/test-once-#{@before_all_time.to_i}"
|
14
|
+
end
|
11
15
|
before do
|
12
16
|
current_server.ssh_exec "echo 'Hello' > /tmp/test-#{time.to_i}"
|
13
17
|
end
|
@@ -20,6 +24,10 @@ describe server(:proxy) do
|
|
20
24
|
expect(ssh.exec!('echo -n Hello')).to eq('Hello')
|
21
25
|
end
|
22
26
|
end
|
27
|
+
it "executes a command on the current server in before all block" do
|
28
|
+
result = current_server.ssh_exec("cat /tmp/test-once-#{@before_all_time.to_i}")
|
29
|
+
expect(result.chomp).to eq('Hello once')
|
30
|
+
end
|
23
31
|
|
24
32
|
end
|
25
33
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: infrataster
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryota Arai
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-07-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|