~ubuntu-branches/ubuntu/karmic/puppet/karmic-security

« back to all changes in this revision

Viewing changes to test/network/client/master.rb

  • Committer: Bazaar Package Importer
  • Author(s): Andrew Pollock
  • Date: 2009-04-13 17:12:47 UTC
  • mfrom: (1.1.9 upstream) (3.1.3 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090413171247-qou3gsiihama09cm
Tags: 0.24.8-1
* New upstream release
* debian/control: Add Nigel Kersten and myself as uploaders
* debian/changelog: wrap long lines
* debian/watch: ignore release candidates
* debian/compat: bump to 5
* debian/control: bump Standards-Version (no changes)

Show diffs side-by-side

added added

removed removed

Lines of Context:
402
402
            client.send(:splay)
403
403
        end
404
404
 
405
 
        time = Puppet::Util::Storage.cache(:configuration)[:splay_time]
406
 
        assert(time, "Splay time was not cached")
407
 
 
408
405
        # Now try it again
409
406
        client = mkclient
410
 
        client.expects(:sleep).with(time)
 
407
        client.expects(:sleep)
411
408
 
412
409
        assert_nothing_raised("Failed to call sleep when splay is true with a cached value") do
413
410
            client.send(:splay)
419
416
        assert_equal(facts["environment"], Puppet[:environment], "Did not add environment to client facts")
420
417
 
421
418
        # Now set it to a real value
422
 
        Puppet[:environments] = "something,else"
423
 
        Puppet[:environment] = "something"
 
419
        Puppet[:environment] = "something"
424
420
        facts = Puppet::Network::Client::Master.facts
425
421
        assert_equal(facts["environment"], Puppet[:environment], "Did not add environment to client facts")
426
422
    end