~nvalcarcel/ubuntu/lucid/puppet/fix-546677

« back to all changes in this revision

Viewing changes to spec/unit/parser/ast/definition.rb

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2009-12-23 00:48:10 UTC
  • mfrom: (1.1.10 upstream) (3.1.7 squeeze)
  • Revision ID: james.westby@ubuntu.com-20091223004810-3i4oryds922g5n59
Tags: 0.25.1-3ubuntu1
* Merge from debian testing.  Remaining changes:
  - debian/rules:
    + Don't start puppet when first installing puppet.
  - debian/puppet.conf, lib/puppet/defaults.rb:
    + Move templates to /etc/puppet
  - lib/puppet/defaults.rb:
    + Fix /var/lib/puppet/state ownership.
  - man/man8/puppet.conf.8: 
    + Fix broken URL in manpage.
  - debian/control:
    + Update maintainer accordint to spec.
    + Puppetmaster Recommends -> Suggests
    + Created puppet-testsuite as a seperate. Allow the users to run puppet's 
      testsuite.
  - tests/Rakefile: Fix rakefile so that the testsuite can acutally be ran.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
        @definition.evaluate_code(@resource)
30
30
    end
31
31
 
 
32
    it "should have a get_classname method" do
 
33
        @definition.should respond_to(:get_classname)
 
34
    end
 
35
 
 
36
    it "should return the current classname with get_classname" do
 
37
        @definition.expects(:classname)
 
38
 
 
39
        @definition.get_classname(@scope)
 
40
    end
 
41
 
 
42
    describe "when evaluating" do
 
43
        it "should create a resource whose title comes from get_classname" do
 
44
            @definition.expects(:get_classname).returns("classname")
 
45
 
 
46
            @definition.evaluate(@scope)
 
47
        end
 
48
    end
 
49
 
32
50
#    it "should copy its namespace to the scope"
33
51
#
34
52
#    it "should mark the scope virtual if the resource is virtual"