pickle 0.4.3 → 0.4.4
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/History.txt +11 -0
- data/README.rdoc +2 -0
- data/VERSION +1 -1
- data/features/pickle/create_from_active_record.feature +18 -11
- data/lib/pickle/adapters/mongoid.rb +1 -1
- data/lib/pickle/parser/matchers.rb +1 -1
- data/pickle.gemspec +2 -2
- data/spec/pickle/parser/matchers_spec.rb +1 -1
- data/spec/pickle/parser_spec.rb +6 -2
- metadata +4 -4
data/History.txt
CHANGED
@@ -1,3 +1,14 @@
|
|
1
|
+
== 0.4.4
|
2
|
+
large object space fix, and allow escaped quotes as string values
|
3
|
+
|
4
|
+
* 1 bugfix
|
5
|
+
* When using super-huge GC limits (for speeding up tests), occasionally we'll see abandoned Mongoid::Document classes appear in the ObjectSpace.
|
6
|
+
This patch should fix that. [Devin Walters and Nick Karpenske]
|
7
|
+
|
8
|
+
* 1 improvement
|
9
|
+
* allow escaped quotes (\") in quoted fields [Jonathan Hinkle]
|
10
|
+
|
11
|
+
|
1
12
|
== 0.4.3
|
2
13
|
ruby 1.9.2 compatibility fix
|
3
14
|
|
data/README.rdoc
CHANGED
@@ -347,6 +347,8 @@ To run the features (rails 2.3 only ATM):
|
|
347
347
|
|
348
348
|
The following people have made Pickle better:
|
349
349
|
|
350
|
+
* {Jonathan Hinkle}[http://github.com/hynkle]
|
351
|
+
* {Devin Walters and Nick Karpenske}[http://github.com/bendyworks]
|
350
352
|
* {Marc Lee}[http://github.com/maleko]
|
351
353
|
* {Sebastian Zuchmanski}[http://github.com/sebcioz]
|
352
354
|
* {Paul Gideon Dann}[http://github.com/giddie]
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.4.
|
1
|
+
0.4.4
|
@@ -16,6 +16,10 @@ Feature: I can easily create models from my blueprints
|
|
16
16
|
Then a user should exist with name: "Fred"
|
17
17
|
And a user should exist with status: "crayzee"
|
18
18
|
But a user should not exist with name: "Wilma"
|
19
|
+
|
20
|
+
Scenario: I create a user with quotes in its status, and see if it looks right
|
21
|
+
Given a user exists with name: "Fred", status: "a little \"off\""
|
22
|
+
Then a user should exist with status: "a little \"off\""
|
19
23
|
|
20
24
|
Scenario: I create a user via a mapping
|
21
25
|
Given I exist with status: "pwned", name: "fred"
|
@@ -43,19 +47,22 @@ Feature: I can easily create models from my blueprints
|
|
43
47
|
|
44
48
|
Scenario: create and find using tables
|
45
49
|
Given the following users exist:
|
46
|
-
| name
|
47
|
-
| Jim
|
48
|
-
| Ethel
|
50
|
+
| name | status |
|
51
|
+
| Jim | married |
|
52
|
+
| Ethel | in a relationship with x |
|
53
|
+
| Garvin | in an "open" relationship |
|
49
54
|
Then the following users should exist:
|
50
|
-
| name
|
51
|
-
| Jim
|
52
|
-
| Ethel
|
55
|
+
| name |
|
56
|
+
| Jim |
|
57
|
+
| Ethel |
|
58
|
+
| Garvin |
|
53
59
|
And the following users should exist:
|
54
|
-
| status
|
55
|
-
| married
|
56
|
-
| in a relationship with x
|
57
|
-
|
58
|
-
And the
|
60
|
+
| status |
|
61
|
+
| married |
|
62
|
+
| in a relationship with x |
|
63
|
+
| in an "open" relationship |
|
64
|
+
And the 1st user should be the 4th user
|
65
|
+
And the 3rd user should be the last user
|
59
66
|
|
60
67
|
Scenario: create and find using tables with referencable names
|
61
68
|
Given the following users exist:
|
data/pickle.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{pickle}
|
8
|
-
s.version = "0.4.
|
8
|
+
s.version = "0.4.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Ian White"]
|
12
|
-
s.date = %q{2010-
|
12
|
+
s.date = %q{2010-12-14}
|
13
13
|
s.description = %q{Easy model creation and reference in your cucumber features}
|
14
14
|
s.email = %q{ian.w.white@gmail.com}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -41,7 +41,7 @@ describe Pickle::Parser::Matchers do
|
|
41
41
|
atom_should_match :match_label, [': "gday"', ': "gday mate"']
|
42
42
|
atom_should_not_match :match_label, [': "gday""', ': gday']
|
43
43
|
|
44
|
-
atom_should_match :match_field, ['foo: "this is the life"', 'bar_man: "and so is this"', 'boolean: false', 'boolean: true', 'numeric: 10', 'numeric: 12.5', 'numeric: +10', 'numeric: +12.5', 'numeric: -10', 'numeric: -12.5', 'nil_field: nil']
|
44
|
+
atom_should_match :match_field, ['foo: "this is the life"', 'bar_man: "and so is this"', 'quoted_baz: "words \"in quotes\""', 'boolean: false', 'boolean: true', 'numeric: 10', 'numeric: 12.5', 'numeric: +10', 'numeric: +12.5', 'numeric: -10', 'numeric: -12.5', 'nil_field: nil']
|
45
45
|
atom_should_not_match :match_field, ['foo bar: "this aint workin"', 'not_numeric: --10', 'not_numeric: -ten']
|
46
46
|
|
47
47
|
atom_should_match :match_fields, ['foo: "bar"', 'foo: "bar", baz: "bah"']
|
data/spec/pickle/parser_spec.rb
CHANGED
@@ -53,6 +53,10 @@ describe Pickle::Parser do
|
|
53
53
|
it '(\'foo: "bar"\') should == { "foo" => "bar"}' do
|
54
54
|
@parser.parse_fields('foo: "bar"').should == { "foo" => "bar"}
|
55
55
|
end
|
56
|
+
|
57
|
+
it '(\'foo: "something \"quoted\""\') should == { "foo" => "bar"}' do
|
58
|
+
@parser.parse_fields('foo: "something \"quoted\""').should == { "foo" => 'something "quoted"' }
|
59
|
+
end
|
56
60
|
|
57
61
|
it '("bool: true") should == { "bool" => true}' do
|
58
62
|
@parser.parse_fields('bool: true').should == {"bool" => true}
|
@@ -70,8 +74,8 @@ describe Pickle::Parser do
|
|
70
74
|
@parser.parse_fields('float: 10.1').should == {"float" => 10.1}
|
71
75
|
end
|
72
76
|
|
73
|
-
it '(\'foo: "bar", bar_man: "wonga wonga", gump: 123\') should == {"foo" => "bar", "bar_man" => "wonga wonga", "gump" => 123}' do
|
74
|
-
@parser.parse_fields('foo: "bar", bar_man: "wonga wonga", gump: 123').should == {"foo" => "bar", "bar_man" => "wonga wonga", "gump" => 123}
|
77
|
+
it '(\'foo: "bar", bar_man: "wonga wonga", baz_woman: "one \"two\" three", gump: 123\') should == {"foo" => "bar", "bar_man" => "wonga wonga", "gump" => 123}' do
|
78
|
+
@parser.parse_fields('foo: "bar", bar_man: "wonga wonga", baz_woman: "one \"two\" three", gump: 123').should == {"foo" => "bar", "bar_man" => "wonga wonga", "baz_woman" => "one \"two\" three", "gump" => 123}
|
75
79
|
end
|
76
80
|
end
|
77
81
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pickle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 7
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 4
|
9
|
-
-
|
10
|
-
version: 0.4.
|
9
|
+
- 4
|
10
|
+
version: 0.4.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Ian White
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-
|
18
|
+
date: 2010-12-14 00:00:00 +00:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|