up to 0.11.3
[packages/gem2rpm.git] / style.patch
1 --- gem2rpm-0.9.2/lib/gem2rpm/helpers.rb~       2013-04-29 23:19:15.000000000 +0300
2 +++ gem2rpm-0.9.2/lib/gem2rpm/helpers.rb        2013-04-29 23:24:07.509077652 +0300
3 @@ -24,7 +24,7 @@
4      # '<' pair.
5      def self.expand_pessimistic_requirement(requirement)
6        next_version = Gem::Version.create(requirement.last).bump
7 -      return ['=>', requirement.last], ['<', next_version]
8 +      return ['>=', requirement.last], ['<', next_version]
9      end
10  
11      # Expands the not equal version operator '!=' into equivalent '<' and
12 --- gem2rpm-0.11.3/test/test_helpers.rb~        2016-05-23 19:34:28.000000000 +0300
13 +++ gem2rpm-0.11.3/test/test_helpers.rb 2016-05-23 19:35:00.032567329 +0300
14 @@ -19,12 +19,12 @@
15  
16    def test_first_level_pessimistic_version_constraint
17      r = Gem::Requirement.new(["~> 1.2"])
18 -    assert_equal(["=> 1.2", "< 2"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
19 +    assert_equal([">= 1.2", "< 2"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
20    end
21  
22    def test_second_level_pessimistic_version_constraint
23      r = Gem::Requirement.new(["~> 1.2.3"])
24 -    assert_equal(["=> 1.2.3", "< 1.3"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
25 +    assert_equal([">= 1.2.3", "< 1.3"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
26    end
27  
28    def test_pessimistic_version_constraint_with_trailing_text
29 @@ -33,12 +33,12 @@
30      return if gem_version >= Gem::Version.create("1.3.2")
31  
32      r = Gem::Requirement.new(["~> 1.2.3.beta.8"])
33 -    assert_equal(["=> 1.2.3.beta.8", "< 1.3"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
34 +    assert_equal([">= 1.2.3.beta.8", "< 1.3"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
35    end
36  
37    def test_second_level_pessimistic_version_constraint_with_two_digit_version
38      r = Gem::Requirement.new(["~> 1.12.3"])
39 -    assert_equal(["=> 1.12.3", "< 1.13"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
40 +    assert_equal([">= 1.12.3", "< 1.13"], Gem2Rpm::Helpers.requirement_versions_to_rpm(r))
41    end
42  
43    def test_first_level_not_equal_version_constraint
This page took 0.220412 seconds and 3 git commands to generate.