require 'support/integration_helper' require 'chef/knife/raw_essentials' require 'chef/knife/show_essentials' describe 'knife raw' do extend IntegrationSupport include KnifeSupport when_the_chef_server "has one of each thing" do client 'x', '{}' cookbook 'x', '1.0.0', { 'metadata.rb' => 'version "1.0.0"' } data_bag 'x', { 'y' => '{}' } environment 'x', '{}' node 'x', '{}' role 'x', '{}' user 'x', '{}' it 'knife raw /nodes/x returns the node', :pending => (RUBY_VERSION < "1.9") do knife('raw /nodes/x').should_succeed < (RUBY_VERSION < "1.9") do knife('raw -m DELETE /roles/x').should_succeed < (RUBY_VERSION < "1.9") do Tempfile.open('raw_put_input') do |file| file.write < (RUBY_VERSION < "1.9") do Tempfile.open('raw_put_input') do |file| file.write <