~ubuntu-branches/ubuntu/precise/puppet/precise-proposed

« back to all changes in this revision

Viewing changes to acceptance/tests/ticket_4059_ralsh_can_change_settings.rb

  • Committer: Package Import Robot
  • Author(s): Micah Anderson
  • Date: 2012-02-23 18:24:48 UTC
  • mfrom: (1.1.28) (3.1.36 sid)
  • Revision ID: package-import@ubuntu.com-20120223182448-belun93murza4w99
Tags: 2.7.11-1
* New upstream release
* Urgency set to high due to regressions in previous release
  and security vulnerabilities
* Execs when run with a user specified, but no group, get the root
  group. Similarly unexpected privileges are given to providers and
  types (egid remains as root), this is fixed with a patch from
  upstream (CVE-2012-1053)
* Fix Klogin write through symlink (CVE-2012-1054)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
test_name "#4059: ralsh can change settings"
 
2
 
 
3
target = "/tmp/hosts-#4059"
 
4
content = "host example.com ensure=present ip=127.0.0.1 target=#{target}"
 
5
 
 
6
step "cleanup the target file"
 
7
on agents, "rm -f #{target}"
 
8
 
 
9
step "run the resource agent"
 
10
on(agents, puppet_resource(content)) do
 
11
  stdout.index('Host[example.com]/ensure: created') or
 
12
    fail_test("missing notice about host record creation")
 
13
end
 
14
agents.each do |host|
 
15
  on(host, "cat #{target}") do
 
16
    assert_match(/^127\.0\.0\.1\s+example\.com/, stdout, "missing host record in #{target} on #{host}")
 
17
  end
 
18
end
 
19
 
 
20
step "cleanup at the end of the test"
 
21
on agents, "rm -f #{target}"