diff options
author | Thom May <thom@chef.io> | 2017-10-03 15:22:34 -0700 |
---|---|---|
committer | Thom May <thom@chef.io> | 2017-10-03 15:46:16 -0700 |
commit | 8d560b01fd5a3771aff67f3a5463e3e7e7e85b12 (patch) | |
tree | bc5a972bd2b606ae15dd80ffd1b124c7983b8f12 /spec | |
parent | 00e10b3fa2be1f572be207fcb3b1d3bdf135690e (diff) | |
download | chef-8d560b01fd5a3771aff67f3a5463e3e7e7e85b12.tar.gz |
[Route unit tests]: Ensure we go down the new file pathtm/route_tests
This should make us more robust in the face of the enemy
Signed-off-by: Thom May <thom@chef.io>
Diffstat (limited to 'spec')
-rw-r--r-- | spec/unit/provider/route_spec.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/unit/provider/route_spec.rb b/spec/unit/provider/route_spec.rb index 5e655bda0c..ea6ddffb81 100644 --- a/spec/unit/provider/route_spec.rb +++ b/spec/unit/provider/route_spec.rb @@ -236,9 +236,11 @@ describe Chef::Provider::Route do @node.automatic_attrs[:platform] = platform route_file = StringIO.new + allow(File).to receive(:exist?).with("/etc/sysconfig/network").and_return(false) expect(File).to receive(:new).with("/etc/sysconfig/network", "w").and_return(route_file) @run_context.resource_collection << @default_resource @default_provider.generate_config + expect(route_file.string).to match(/GATEWAY=10\.0\.0\.9/) end end |