obvious 0.0.6 → 0.0.7
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.
- data/lib/generators/descriptor.rb +16 -2
- data/lib/obvious/version.rb +1 -1
- metadata +1 -1
@@ -72,6 +72,20 @@ end
|
|
72
72
|
|
73
73
|
filename = "#{Obvious::Generators::Application.instance.dir}/actions/#{snake_name}.rb"
|
74
74
|
File.open(filename, 'w') {|f| f.write(output) }
|
75
|
+
|
76
|
+
output = %Q{require_relative '../../actions/#{snake_name}'
|
77
|
+
|
78
|
+
describe #{action['Action']} do
|
79
|
+
|
80
|
+
it '#{action['Description']}'
|
81
|
+
|
82
|
+
it 'should raise an error with invalid input'
|
83
|
+
|
84
|
+
end
|
85
|
+
}
|
86
|
+
|
87
|
+
filename = "#{Obvious::Generators::Application.instance.dir}/spec/actions/#{snake_name}_spec.rb"
|
88
|
+
File.open(filename, 'w') {|f| f.write(output) }
|
75
89
|
end
|
76
90
|
|
77
91
|
def process_jacks
|
@@ -96,8 +110,8 @@ end
|
|
96
110
|
entity_requires = ''
|
97
111
|
|
98
112
|
@entities.each do |k, v|
|
99
|
-
|
100
|
-
entity_requires << "require_relative '../entities/#{
|
113
|
+
snake_name = k.gsub(/(.)([A-Z])/,'\1_\2').downcase
|
114
|
+
entity_requires << "require_relative '../entities/#{snake_name}'\n"
|
101
115
|
end
|
102
116
|
|
103
117
|
entity_requires
|
data/lib/obvious/version.rb
CHANGED