From 935d3ce15b7c3c31e1a6fdca92021d9f29e19cf0 Mon Sep 17 00:00:00 2001 From: Marco Nenciarini Date: Mon, 2 Dec 2013 13:17:00 +0100 Subject: [PATCH] Fix the name of sources.list.d file resource in apt::ppa --- manifests/ppa.pp | 2 +- spec/defines/ppa_spec.rb | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/manifests/ppa.pp b/manifests/ppa.pp index 253e72f..730bf7d 100644 --- a/manifests/ppa.pp +++ b/manifests/ppa.pp @@ -48,7 +48,7 @@ define apt::ppa( logoutput => 'on_failure', notify => Exec['apt_update'], require => [ - File[$sources_list_d], + File['sources.list.d'], Package[$package], ], } diff --git a/spec/defines/ppa_spec.rb b/spec/defines/ppa_spec.rb index 5b59f57..a05ca30 100644 --- a/spec/defines/ppa_spec.rb +++ b/spec/defines/ppa_spec.rb @@ -46,7 +46,7 @@ describe 'apt::ppa', :type => :define do it { should contain_exec("add-apt-repository-#{t}").with( 'command' => "/usr/bin/add-apt-repository #{options} #{t}", 'unless' => "/usr/bin/test -s /etc/apt/sources.list.d/#{filename}", - 'require' => ["File[/etc/apt/sources.list.d]", "Package[#{package}]"], + 'require' => ["File[sources.list.d]", "Package[#{package}]"], 'notify' => "Exec[apt_update]" ) } @@ -75,7 +75,7 @@ describe 'apt::ppa', :type => :define do 'environment' => [], 'command' => "/usr/bin/add-apt-repository #{options} #{title}", 'unless' => "/usr/bin/test -s /etc/apt/sources.list.d/#{filename}", - 'require' => ["File[/etc/apt/sources.list.d]", "Package[#{package}]"], + 'require' => ["File[sources.list.d]", "Package[#{package}]"], 'notify' => "Exec[apt_update]" ) } @@ -101,7 +101,7 @@ describe 'apt::ppa', :type => :define do ], 'command' => "/usr/bin/add-apt-repository #{options} #{title}", 'unless' => "/usr/bin/test -s /etc/apt/sources.list.d/#{filename}", - 'require' => ["File[/etc/apt/sources.list.d]", "Package[#{package}]"], + 'require' => ["File[sources.list.d]", "Package[#{package}]"], 'notify' => "Exec[apt_update]" ) } -- 2.45.2