pickle 0.1.16
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +2 -0
- data/History.txt +165 -0
- data/License.txt +20 -0
- data/README.rdoc +205 -0
- data/Rakefile +116 -0
- data/Todo.txt +4 -0
- data/VERSION +1 -0
- data/features/app/app.rb +112 -0
- data/features/app/blueprints.rb +11 -0
- data/features/app/factories.rb +23 -0
- data/features/app/views/notifier/email.erb +1 -0
- data/features/app/views/notifier/user_email.erb +6 -0
- data/features/email/email.feature +38 -0
- data/features/generator/generators.feature +54 -0
- data/features/path/models_page.feature +44 -0
- data/features/path/named_route_page.feature +10 -0
- data/features/pickle/create_from_active_record.feature +20 -0
- data/features/pickle/create_from_factory_girl.feature +43 -0
- data/features/pickle/create_from_machinist.feature +38 -0
- data/features/step_definitions/email_steps.rb +50 -0
- data/features/step_definitions/extra_email_steps.rb +7 -0
- data/features/step_definitions/fork_steps.rb +4 -0
- data/features/step_definitions/generator_steps.rb +42 -0
- data/features/step_definitions/path_steps.rb +14 -0
- data/features/step_definitions/pickle_steps.rb +41 -0
- data/features/support/env.rb +34 -0
- data/features/support/paths.rb +46 -0
- data/garlic.rb +36 -0
- data/init.rb +0 -0
- data/lib/pickle.rb +26 -0
- data/lib/pickle/adapter.rb +87 -0
- data/lib/pickle/config.rb +48 -0
- data/lib/pickle/email.rb +36 -0
- data/lib/pickle/email/parser.rb +18 -0
- data/lib/pickle/email/world.rb +13 -0
- data/lib/pickle/parser.rb +65 -0
- data/lib/pickle/parser/matchers.rb +87 -0
- data/lib/pickle/path.rb +44 -0
- data/lib/pickle/path/world.rb +5 -0
- data/lib/pickle/session.rb +151 -0
- data/lib/pickle/session/parser.rb +24 -0
- data/lib/pickle/version.rb +6 -0
- data/lib/pickle/world.rb +9 -0
- data/pickle.gemspec +107 -0
- data/rails_generators/pickle/pickle_generator.rb +41 -0
- data/rails_generators/pickle/templates/email_steps.rb +50 -0
- data/rails_generators/pickle/templates/env.rb +14 -0
- data/rails_generators/pickle/templates/paths.rb +20 -0
- data/rails_generators/pickle/templates/pickle_steps.rb +41 -0
- data/spec/lib/pickle_adapter_spec.rb +164 -0
- data/spec/lib/pickle_config_spec.rb +97 -0
- data/spec/lib/pickle_email_parser_spec.rb +49 -0
- data/spec/lib/pickle_email_spec.rb +131 -0
- data/spec/lib/pickle_parser_matchers_spec.rb +70 -0
- data/spec/lib/pickle_parser_spec.rb +154 -0
- data/spec/lib/pickle_path_spec.rb +77 -0
- data/spec/lib/pickle_session_spec.rb +337 -0
- data/spec/lib/pickle_spec.rb +24 -0
- data/spec/spec_helper.rb +38 -0
- metadata +122 -0
@@ -0,0 +1,24 @@
|
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), '../spec_helper'))
|
2
|
+
|
3
|
+
describe Pickle do
|
4
|
+
it ".config should be same object on multiple calls" do
|
5
|
+
Pickle.config.should == Pickle.config
|
6
|
+
end
|
7
|
+
|
8
|
+
it ".configure should configure the .config object" do
|
9
|
+
Pickle.config.should_receive(:foo).with(:bar)
|
10
|
+
Pickle.configure do |c|
|
11
|
+
c.foo :bar
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
it ".parser should create a parser with the default config" do
|
16
|
+
Pickle.instance_variable_set('@parser', nil)
|
17
|
+
Pickle::Parser.should_receive(:new).with(:config => Pickle.config)
|
18
|
+
Pickle.parser
|
19
|
+
end
|
20
|
+
|
21
|
+
it ".parser should be same object on multiple calls" do
|
22
|
+
Pickle.parser.should == Pickle.parser
|
23
|
+
end
|
24
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
# This file is copied to ~/spec when you run 'ruby script/generate rspec'
|
2
|
+
# from the project root directory.
|
3
|
+
ENV["RAILS_ENV"] ||= "test"
|
4
|
+
require File.expand_path(File.join(File.dirname(__FILE__), "../../../../config/environment"))
|
5
|
+
require 'spec/rails'
|
6
|
+
|
7
|
+
# APP SETUP
|
8
|
+
|
9
|
+
# Models
|
10
|
+
class User < ActiveRecord::Base
|
11
|
+
end
|
12
|
+
|
13
|
+
class FastCar < ActiveRecord::Base
|
14
|
+
end
|
15
|
+
|
16
|
+
class Event < ActiveRecord::Base
|
17
|
+
class Create < Event
|
18
|
+
end
|
19
|
+
|
20
|
+
class Update < Event
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
# Factories
|
25
|
+
require 'factory_girl'
|
26
|
+
|
27
|
+
Factory.define :user do |u|
|
28
|
+
end
|
29
|
+
|
30
|
+
Factory.define :super_admin, :class => User do |u|
|
31
|
+
end
|
32
|
+
|
33
|
+
Factory.define :fast_car do |c|
|
34
|
+
end
|
35
|
+
|
36
|
+
# Machinist
|
37
|
+
require 'machinist/active_record'
|
38
|
+
|
metadata
ADDED
@@ -0,0 +1,122 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: pickle
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.16
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Ian White
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
|
12
|
+
date: 2009-10-15 00:00:00 +01:00
|
13
|
+
default_executable:
|
14
|
+
dependencies: []
|
15
|
+
|
16
|
+
description: Easy model creation and reference in your cucumber features
|
17
|
+
email: ian.w.white@gmail.com
|
18
|
+
executables: []
|
19
|
+
|
20
|
+
extensions: []
|
21
|
+
|
22
|
+
extra_rdoc_files:
|
23
|
+
- README.rdoc
|
24
|
+
files:
|
25
|
+
- .gitignore
|
26
|
+
- History.txt
|
27
|
+
- License.txt
|
28
|
+
- README.rdoc
|
29
|
+
- Rakefile
|
30
|
+
- Todo.txt
|
31
|
+
- VERSION
|
32
|
+
- features/app/app.rb
|
33
|
+
- features/app/blueprints.rb
|
34
|
+
- features/app/factories.rb
|
35
|
+
- features/app/views/notifier/email.erb
|
36
|
+
- features/app/views/notifier/user_email.erb
|
37
|
+
- features/email/email.feature
|
38
|
+
- features/generator/generators.feature
|
39
|
+
- features/path/models_page.feature
|
40
|
+
- features/path/named_route_page.feature
|
41
|
+
- features/pickle/create_from_active_record.feature
|
42
|
+
- features/pickle/create_from_factory_girl.feature
|
43
|
+
- features/pickle/create_from_machinist.feature
|
44
|
+
- features/step_definitions/email_steps.rb
|
45
|
+
- features/step_definitions/extra_email_steps.rb
|
46
|
+
- features/step_definitions/fork_steps.rb
|
47
|
+
- features/step_definitions/generator_steps.rb
|
48
|
+
- features/step_definitions/path_steps.rb
|
49
|
+
- features/step_definitions/pickle_steps.rb
|
50
|
+
- features/support/env.rb
|
51
|
+
- features/support/paths.rb
|
52
|
+
- garlic.rb
|
53
|
+
- init.rb
|
54
|
+
- lib/pickle.rb
|
55
|
+
- lib/pickle/adapter.rb
|
56
|
+
- lib/pickle/config.rb
|
57
|
+
- lib/pickle/email.rb
|
58
|
+
- lib/pickle/email/parser.rb
|
59
|
+
- lib/pickle/email/world.rb
|
60
|
+
- lib/pickle/parser.rb
|
61
|
+
- lib/pickle/parser/matchers.rb
|
62
|
+
- lib/pickle/path.rb
|
63
|
+
- lib/pickle/path/world.rb
|
64
|
+
- lib/pickle/session.rb
|
65
|
+
- lib/pickle/session/parser.rb
|
66
|
+
- lib/pickle/version.rb
|
67
|
+
- lib/pickle/world.rb
|
68
|
+
- pickle.gemspec
|
69
|
+
- rails_generators/pickle/pickle_generator.rb
|
70
|
+
- rails_generators/pickle/templates/email_steps.rb
|
71
|
+
- rails_generators/pickle/templates/env.rb
|
72
|
+
- rails_generators/pickle/templates/paths.rb
|
73
|
+
- rails_generators/pickle/templates/pickle_steps.rb
|
74
|
+
- spec/lib/pickle_adapter_spec.rb
|
75
|
+
- spec/lib/pickle_config_spec.rb
|
76
|
+
- spec/lib/pickle_email_parser_spec.rb
|
77
|
+
- spec/lib/pickle_email_spec.rb
|
78
|
+
- spec/lib/pickle_parser_matchers_spec.rb
|
79
|
+
- spec/lib/pickle_parser_spec.rb
|
80
|
+
- spec/lib/pickle_path_spec.rb
|
81
|
+
- spec/lib/pickle_session_spec.rb
|
82
|
+
- spec/lib/pickle_spec.rb
|
83
|
+
- spec/spec_helper.rb
|
84
|
+
has_rdoc: true
|
85
|
+
homepage: http://github.com/ianwhite/pickle/tree
|
86
|
+
licenses: []
|
87
|
+
|
88
|
+
post_install_message:
|
89
|
+
rdoc_options:
|
90
|
+
- --charset=UTF-8
|
91
|
+
require_paths:
|
92
|
+
- lib
|
93
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
94
|
+
requirements:
|
95
|
+
- - ">="
|
96
|
+
- !ruby/object:Gem::Version
|
97
|
+
version: "0"
|
98
|
+
version:
|
99
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: "0"
|
104
|
+
version:
|
105
|
+
requirements: []
|
106
|
+
|
107
|
+
rubyforge_project: pickle
|
108
|
+
rubygems_version: 1.3.4
|
109
|
+
signing_key:
|
110
|
+
specification_version: 3
|
111
|
+
summary: Easy model creation and reference in your cucumber features
|
112
|
+
test_files:
|
113
|
+
- spec/lib/pickle_adapter_spec.rb
|
114
|
+
- spec/lib/pickle_config_spec.rb
|
115
|
+
- spec/lib/pickle_email_parser_spec.rb
|
116
|
+
- spec/lib/pickle_email_spec.rb
|
117
|
+
- spec/lib/pickle_parser_matchers_spec.rb
|
118
|
+
- spec/lib/pickle_parser_spec.rb
|
119
|
+
- spec/lib/pickle_path_spec.rb
|
120
|
+
- spec/lib/pickle_session_spec.rb
|
121
|
+
- spec/lib/pickle_spec.rb
|
122
|
+
- spec/spec_helper.rb
|