diff options
author | Vivek Singh <vivek.singh@msystechnologies.com> | 2019-10-27 11:43:48 +0530 |
---|---|---|
committer | Vivek Singh <vivek.singh@msystechnologies.com> | 2019-12-02 22:06:02 +0530 |
commit | 87fc4d22f869bde6f3fe3756718b6d12713c2bab (patch) | |
tree | e6144abf56579ca001ff528f3c22557d8d3ea08d /spec/unit/provider | |
parent | 9009b12f14272522c08b2d19c94ae3e418867f56 (diff) | |
download | chef-87fc4d22f869bde6f3fe3756718b6d12713c2bab.tar.gz |
Fix apt_repository uri single/double quotes and spaces
Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
Diffstat (limited to 'spec/unit/provider')
-rw-r--r-- | spec/unit/provider/apt_repository_spec.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/unit/provider/apt_repository_spec.rb b/spec/unit/provider/apt_repository_spec.rb index 11d505dad8..df39abcd4e 100644 --- a/spec/unit/provider/apt_repository_spec.rb +++ b/spec/unit/provider/apt_repository_spec.rb @@ -226,27 +226,27 @@ C5986B4F1257FFA86632CBA746181433FBB75451 describe "#build_repo" do it "creates a repository string" do - target = %Q{deb "http://test/uri" unstable main\n} + target = "deb http://test/uri unstable main\n" expect(provider.build_repo("http://test/uri", "unstable", "main", false, nil)).to eql(target) end it "creates a repository string with no distribution" do - target = %Q{deb "http://test/uri" main\n} + target = "deb http://test/uri main\n" expect(provider.build_repo("http://test/uri", nil, "main", false, nil)).to eql(target) end it "creates a repository string with source" do - target = %Q{deb "http://test/uri" unstable main\ndeb-src "http://test/uri" unstable main\n} + target = "deb http://test/uri unstable main\ndeb-src http://test/uri unstable main\n" expect(provider.build_repo("http://test/uri", "unstable", "main", false, nil, true)).to eql(target) end it "creates a repository string with options" do - target = %Q{deb [trusted=yes] "http://test/uri" unstable main\n} + target = "deb [trusted=yes] http://test/uri unstable main\n" expect(provider.build_repo("http://test/uri", "unstable", "main", true, nil)).to eql(target) end it "handles a ppa repo" do - target = %Q{deb "http://ppa.launchpad.net/chef/main/ubuntu" unstable main\n} + target = "deb http://ppa.launchpad.net/chef/main/ubuntu unstable main\n" expect(provider).to receive(:make_ppa_url).with("ppa:chef/main").and_return("http://ppa.launchpad.net/chef/main/ubuntu") expect(provider.build_repo("ppa:chef/main", "unstable", "main", false, nil)).to eql(target) end |