has_price 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.0
1
+ 1.1.1
data/has_price.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{has_price}
8
- s.version = "1.1.0"
8
+ s.version = "1.1.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Maxim Chernyak"]
12
- s.date = %q{2009-12-02}
12
+ s.date = %q{2010-01-18}
13
13
  s.description = %q{A convenient DSL for defining complex price reader/serializer in a class and organizing a price breakdown. Price can be declared with items and groups which depend on other attributes. Price is a very simple subclass of Hash. This provides for easy serialization and flexibility in case of implementation changes. This way you can conveniently store the whole price breakdown in your serialized receipts. It also provides magic methods for convenient access, but can be fully treated as a regular Hash with some sprinkles on top.}
14
14
  s.email = %q{max@bitsonnet.com}
15
15
  s.extra_rdoc_files = [
data/lib/has_price.rb CHANGED
@@ -1,11 +1,11 @@
1
1
  require File.dirname(__FILE__) + "/has_price/core_extensions/array.rb"
2
2
  require File.dirname(__FILE__) + "/has_price/core_extensions/string.rb"
3
3
 
4
- unless Array.instance_methods.include? "extract_options!"
4
+ unless ["extract_options!", :extract_options!].any?{|meth| Array.instance_methods.include?(meth)}
5
5
  Array.send :include, HasPrice::CoreExtensions::Array
6
6
  end
7
7
 
8
- unless String.instance_methods.include? "underscore"
8
+ unless ["underscore", :underscore].any?{|meth| String.instance_methods.include?(meth)}
9
9
  String.send :include, HasPrice::CoreExtensions::String
10
10
  end
11
11
 
@@ -14,7 +14,7 @@ class TestHasPrice < Test::Unit::TestCase
14
14
  end
15
15
 
16
16
  should "gain #price method" do
17
- assert Product.instance_methods.include? "price"
17
+ assert ["price", :price].any?{|meth| Product.instance_methods.include?(meth)}
18
18
  end
19
19
 
20
20
  should "return empty Price object" do
@@ -36,7 +36,7 @@ class TestHasPrice < Test::Unit::TestCase
36
36
  end
37
37
 
38
38
  should "gain #price method" do
39
- assert Product.instance_methods.include? "price"
39
+ assert ["price", :price].any?{|meth| Product.instance_methods.include?(meth)}
40
40
  end
41
41
 
42
42
  should "return price object" do
@@ -74,7 +74,7 @@ class TestHasPrice < Test::Unit::TestCase
74
74
  end
75
75
 
76
76
  should "gain #total_price method" do
77
- assert Product.instance_methods.include? "total_price"
77
+ assert ["total_price", :total_price].any?{|meth| Product.instance_methods.include?(meth)}
78
78
  end
79
79
  end
80
80
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: has_price
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Maxim Chernyak
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-12-02 00:00:00 -05:00
12
+ date: 2010-01-18 00:00:00 -05:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency