lawrencepit-autocode 0.9.5 → 0.9.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. data/test/autocreate.rb +17 -0
  2. metadata +1 -1
data/test/autocreate.rb CHANGED
@@ -40,4 +40,21 @@ describe "A module where autocreate has been called" do
40
40
  Duffel.unload
41
41
  end
42
42
 
43
+ it "should be possible to include autocode" do
44
+ module Waves
45
+ include Autocode
46
+ autocreate(:TestLib, Module.new) do
47
+ include Autocode
48
+ autocreate_class
49
+ autoload_class
50
+ end
51
+ end
52
+ Waves::TestLib::TheOneAndOnlyClass.help().should == "class help"
53
+ Waves::TestLib::AnyThing.name.should == "Waves::TestLib::AnyThing"
54
+ lambda { Waves::TestLib::TheOneAndOnlyModule }.should.raise TypeError
55
+ Waves::TestLib::ThePretender.name.should == "Waves::TestLib::ThePretender"
56
+ lambda { Waves::TestLib::ThePretender.help() }.should.raise NoMethodError
57
+ Waves.unload
58
+ end
59
+
43
60
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lawrencepit-autocode
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.5
4
+ version: 0.9.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dan Yoder