diff options
author | Thom May <thom@chef.io> | 2016-03-30 09:54:01 +0100 |
---|---|---|
committer | Thom May <thom@chef.io> | 2016-03-30 09:54:01 +0100 |
commit | b975dce9609d74d349f6904da61541b15e43e806 (patch) | |
tree | 04abb403a826ea83f9df237533c7998b5b677c72 /spec/integration/knife/upload_spec.rb | |
parent | d55259b34cbcc6b9b7697cdb38800aa3aeef6f96 (diff) | |
download | chef-tm/ruby_zero_two.tar.gz |
do legwork in preparation for ruby rolestm/ruby_zero_two
Diffstat (limited to 'spec/integration/knife/upload_spec.rb')
-rw-r--r-- | spec/integration/knife/upload_spec.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/spec/integration/knife/upload_spec.rb b/spec/integration/knife/upload_spec.rb index 038bbad216..4fe67ccf7e 100644 --- a/spec/integration/knife/upload_spec.rb +++ b/spec/integration/knife/upload_spec.rb @@ -154,6 +154,25 @@ EOM end end + context 'the role is in ruby', focus: true do + before do + file "roles/x.rb", <<EOM +name "x" +description "blargle" +EOM + end + + it 'knife upload changes the role' do + knife("upload /").should_succeed "Updated /roles/x.json\n" + knife("diff --name-status /").should_succeed "" + end + + it 'knife upload --no-diff does not change the role' do + knife("upload --no-diff /").should_succeed "" + knife("diff --name-status /").should_succeed "M\t/roles/x.rb\n" + end + end + context "when cookbook metadata has a self-dependency" do before do file "cookbooks/x/metadata.rb", "name 'x'; version '1.0.0'; depends 'x'" |