unixoid-challenge 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/challenge_spec.rb +5 -2
- data/lib/unixoid/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 821f642f54aed4725d643e4092c853a9b1b51271
|
4
|
+
data.tar.gz: 734ade33d5ec3a3fb48b5fc1fdd1873848c11f3f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 14964894b315d387d5a3407c2082a77c3ccdcdb9979d215f99eb7bcea90a85b50bc259e0bd7ca9325a676cc861a566fe41c0a0d485bddaea950eb129032d938d
|
7
|
+
data.tar.gz: bf6c3eb087b32b03029278d08c23117df98ed9bbf28b7b05bb153f61880d4ad016c3f0f5ffe98de5055a968ac82580dd59dfe9f8bdaf5119ae6646cd1e4aa613
|
data/challenge_spec.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'cocaine'
|
2
|
+
|
1
3
|
describe "Unixoid test" do
|
2
4
|
|
3
5
|
it "1. should have a my/private/files directory" do
|
@@ -61,8 +63,9 @@ describe "Unixoid test" do
|
|
61
63
|
end
|
62
64
|
|
63
65
|
it "13. should have the the first three env vars in my/private/files/first-three-env.txt" do
|
64
|
-
lines = File.readlines('my/private/files/first-three-env.txt')
|
65
|
-
|
66
|
+
lines = File.readlines('my/private/files/first-three-env.txt').map(&:chomp)
|
67
|
+
command = Cocaine::CommandLine.new("echo \"#{lines.join("\n")}\" | sort", "", expected_outcodes: [0, 2], swallow_stderr: true).run.sub(/^\n+/, "").split("\n")
|
68
|
+
expect(command).to eq lines
|
66
69
|
expect(lines.count).to eq(3)
|
67
70
|
end
|
68
71
|
|
data/lib/unixoid/version.rb
CHANGED