Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# template => 'motd/motd.erb',
# }
#
define datacat(
define datacat (
$ensure = 'file',
$template = undef,
$template_body = undef,
Expand Down Expand Up @@ -50,10 +50,10 @@

if $ensure == 'absent' {
file { $title:
ensure => $ensure,
path => $path,
backup => $backup,
force => $force,
ensure => $ensure,
path => $path,
backup => $backup,
force => $force,
}
} else {
file { $title:
Expand Down
1 change: 0 additions & 1 deletion spec/fixtures/modules/demo1/manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@
data => { bar => 2 },
}
}

5 changes: 2 additions & 3 deletions spec/fixtures/modules/demo2/manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@

datacat_fragment { 'data foo => 1, 2':
target => '/tmp/demo2',
data => { foo => [ 1, 2 ] },
data => { foo => [1, 2] },
}

datacat_fragment { 'data foo => 2, 3':
target => '/tmp/demo2',
data => { foo => [ 2, 3 ] },
data => { foo => [2, 3] },
}
}

4 changes: 2 additions & 2 deletions spec/fixtures/modules/demo3/manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
datacat_fragment { 'foo host':
target => '/tmp/demo3',
data => {
device => [ $host1 ],
device => [$host1],
},
}

$ilo_fqdn = 'foo-ilo.example.com'
datacat_fragment { 'foo ilo':
target => '/tmp/demo3',
data => {
device => [ $ilo_fqdn ],
device => [$ilo_fqdn],
},
}
}
4 changes: 2 additions & 2 deletions spec/fixtures/modules/issue1/manifests/init.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This should repo the scope error from github issue #1
class issue1 {
datacat { "/tmp/issue1.1":
template => "issue1/refers_to_scope.erb",
datacat { '/tmp/issue1.1':
template => 'issue1/refers_to_scope.erb',
}
}
12 changes: 6 additions & 6 deletions test/integration/default/site.pp
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
datacat { "/tmp/demo1":
template_body => "<% @data.keys.sort.each do |k| %><%= k %>: <%= @data[k] %>, <% end %>",
datacat { '/tmp/demo1':
template_body => '<% @data.keys.sort.each do |k| %><%= k %>: <%= @data[k] %>, <% end %>',
}

datacat_fragment { "foo":
datacat_fragment { 'foo':
target => '/tmp/demo1',
data => { foo => "one" },
data => { foo => 'one' },
}

datacat_fragment { "bar":
datacat_fragment { 'bar':
target => '/tmp/demo1',
data => { bar => "two" },
data => { bar => 'two' },
}