spec/lib/build_matrix_spec.rb in evrone-ci-router-0.2.0.pre19 vs spec/lib/build_matrix_spec.rb in evrone-ci-router-0.2.0.pre20
- old
+ new
@@ -37,10 +37,23 @@
it "should copy before_script from source" do
expect(subject.map(&:before_script).uniq).to eq [["echo before_script"]]
end
+ context "without any matrix keys" do
+ let(:attributes) { {
+ script: %w{ /bin/true },
+ } }
+
+ it { should have(1).item }
+ its("first.attributes") { should eq(
+ "env"=>{"matrix"=>[], "global"=>[]},
+ "script"=>["/bin/true"],
+ "before_script"=>[]
+ )}
+ end
+
context "values" do
it { should have(12).items }
context "attributes" do
@@ -68,9 +81,10 @@
rvm: %w{ 2.0.0 },
} }
it { should eq ['rvm:2.0.0'] }
end
+
end
end
end
context "attributes_for_new_travises_with_merged_env" do