compass-rails 2.0.1 → 4.0.0

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.
Files changed (48) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +1 -0
  3. data/.travis.yml +23 -4
  4. data/Appraisals +18 -9
  5. data/CHANGELOG.md +18 -0
  6. data/Gemfile +4 -7
  7. data/README.md +12 -11
  8. data/Rakefile +4 -23
  9. data/compass-rails.gemspec +3 -2
  10. data/gemfiles/rails52.gemfile +20 -0
  11. data/gemfiles/rails60.gemfile +21 -0
  12. data/gemfiles/rails_edge.gemfile +21 -0
  13. data/lib/compass-rails/patches/3_1.rb +2 -2
  14. data/lib/compass-rails/patches/4_0.rb +20 -17
  15. data/lib/compass-rails/patches/compass.rb +2 -2
  16. data/lib/compass-rails/patches/importer.rb +10 -12
  17. data/lib/compass-rails/patches/sass_importer.rb +67 -7
  18. data/lib/compass-rails/patches/sprite_importer.rb +4 -4
  19. data/lib/compass-rails/patches.rb +0 -3
  20. data/lib/compass-rails/railties/3_1.rb +5 -12
  21. data/lib/compass-rails/railties/4_0.rb +11 -9
  22. data/lib/compass-rails/railties.rb +1 -3
  23. data/lib/compass-rails/version.rb +1 -3
  24. data/lib/compass-rails.rb +12 -125
  25. data/test/compass_rails_spec.rb +58 -0
  26. data/test/fixtures/assets/images/letters/a.png +0 -0
  27. data/test/fixtures/assets/images/letters/b.png +0 -0
  28. data/test/fixtures/assets/images/numbers/sprite-1.png +0 -0
  29. data/test/fixtures/assets/images/numbers/sprite-2.png +0 -0
  30. data/test/fixtures/assets/stylesheets/application.css.scss +23 -0
  31. data/test/fixtures/assets/stylesheets/partials/_partial_1.scss +3 -0
  32. data/test/fixtures/assets/stylesheets/partials/_partial_2.scss +3 -0
  33. data/test/helpers/command_helper.rb +2 -15
  34. data/test/helpers/debug_helper.rb +1 -1
  35. data/test/helpers/file_helper.rb +2 -17
  36. data/test/helpers/rails_helper.rb +37 -38
  37. data/test/helpers/rails_project.rb +30 -70
  38. data/test/test_helper.rb +8 -3
  39. metadata +50 -18
  40. data/gemfiles/rails31.gemfile +0 -22
  41. data/gemfiles/rails32.gemfile +0 -22
  42. data/gemfiles/rails40.gemfile +0 -22
  43. data/lib/compass-rails/installer.rb +0 -30
  44. data/test/integrations/.gitkeep +0 -0
  45. data/test/integrations/rails_31_test.rb +0 -46
  46. data/test/integrations/rails_32_test.rb +0 -46
  47. data/test/integrations/rails_40_test.rb +0 -46
  48. data/test/units/.gitkeep +0 -0
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: compass-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.1
4
+ version: 4.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Davis
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2014-10-06 00:00:00.000000000 Z
13
+ date: 2020-02-18 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: compass
@@ -26,6 +26,34 @@ dependencies:
26
26
  - - "~>"
27
27
  - !ruby/object:Gem::Version
28
28
  version: 1.0.0
29
+ - !ruby/object:Gem::Dependency
30
+ name: sprockets
31
+ requirement: !ruby/object:Gem::Requirement
32
+ requirements:
33
+ - - "<"
34
+ - !ruby/object:Gem::Version
35
+ version: '4.0'
36
+ type: :runtime
37
+ prerelease: false
38
+ version_requirements: !ruby/object:Gem::Requirement
39
+ requirements:
40
+ - - "<"
41
+ - !ruby/object:Gem::Version
42
+ version: '4.0'
43
+ - !ruby/object:Gem::Dependency
44
+ name: sass-rails
45
+ requirement: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "<"
48
+ - !ruby/object:Gem::Version
49
+ version: '5.1'
50
+ type: :runtime
51
+ prerelease: false
52
+ version_requirements: !ruby/object:Gem::Requirement
53
+ requirements:
54
+ - - "<"
55
+ - !ruby/object:Gem::Version
56
+ version: '5.1'
29
57
  description: Integrate Compass into Rails 3.0 and up.
30
58
  email:
31
59
  - jetviper21@gmail.com
@@ -45,12 +73,11 @@ files:
45
73
  - README.md
46
74
  - Rakefile
47
75
  - compass-rails.gemspec
48
- - gemfiles/rails31.gemfile
49
- - gemfiles/rails32.gemfile
50
- - gemfiles/rails40.gemfile
76
+ - gemfiles/rails52.gemfile
77
+ - gemfiles/rails60.gemfile
78
+ - gemfiles/rails_edge.gemfile
51
79
  - lib/compass-rails.rb
52
80
  - lib/compass-rails/configuration.rb
53
- - lib/compass-rails/installer.rb
54
81
  - lib/compass-rails/patches.rb
55
82
  - lib/compass-rails/patches/3_1.rb
56
83
  - lib/compass-rails/patches/4_0.rb
@@ -64,18 +91,21 @@ files:
64
91
  - lib/compass-rails/railties/4_0.rb
65
92
  - lib/compass-rails/version.rb
66
93
  - sache.json
94
+ - test/compass_rails_spec.rb
67
95
  - test/fixtures/.gitkeep
96
+ - test/fixtures/assets/images/letters/a.png
97
+ - test/fixtures/assets/images/letters/b.png
98
+ - test/fixtures/assets/images/numbers/sprite-1.png
99
+ - test/fixtures/assets/images/numbers/sprite-2.png
100
+ - test/fixtures/assets/stylesheets/application.css.scss
101
+ - test/fixtures/assets/stylesheets/partials/_partial_1.scss
102
+ - test/fixtures/assets/stylesheets/partials/_partial_2.scss
68
103
  - test/helpers/command_helper.rb
69
104
  - test/helpers/debug_helper.rb
70
105
  - test/helpers/file_helper.rb
71
106
  - test/helpers/rails_helper.rb
72
107
  - test/helpers/rails_project.rb
73
- - test/integrations/.gitkeep
74
- - test/integrations/rails_31_test.rb
75
- - test/integrations/rails_32_test.rb
76
- - test/integrations/rails_40_test.rb
77
108
  - test/test_helper.rb
78
- - test/units/.gitkeep
79
109
  homepage: https://github.com/Compass/compass-rails
80
110
  licenses:
81
111
  - MIT
@@ -95,21 +125,23 @@ required_rubygems_version: !ruby/object:Gem::Requirement
95
125
  - !ruby/object:Gem::Version
96
126
  version: '0'
97
127
  requirements: []
98
- rubyforge_project:
99
- rubygems_version: 2.2.2
128
+ rubygems_version: 3.0.3
100
129
  signing_key:
101
130
  specification_version: 4
102
131
  summary: Integrate Compass into Rails 3.0 and up.
103
132
  test_files:
133
+ - test/compass_rails_spec.rb
104
134
  - test/fixtures/.gitkeep
135
+ - test/fixtures/assets/images/letters/a.png
136
+ - test/fixtures/assets/images/letters/b.png
137
+ - test/fixtures/assets/images/numbers/sprite-1.png
138
+ - test/fixtures/assets/images/numbers/sprite-2.png
139
+ - test/fixtures/assets/stylesheets/application.css.scss
140
+ - test/fixtures/assets/stylesheets/partials/_partial_1.scss
141
+ - test/fixtures/assets/stylesheets/partials/_partial_2.scss
105
142
  - test/helpers/command_helper.rb
106
143
  - test/helpers/debug_helper.rb
107
144
  - test/helpers/file_helper.rb
108
145
  - test/helpers/rails_helper.rb
109
146
  - test/helpers/rails_project.rb
110
- - test/integrations/.gitkeep
111
- - test/integrations/rails_31_test.rb
112
- - test/integrations/rails_32_test.rb
113
- - test/integrations/rails_40_test.rb
114
147
  - test/test_helper.rb
115
- - test/units/.gitkeep
@@ -1,22 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "rb-fsevent", :require=>false
6
- gem "ruby_gntp", :require=>false
7
- gem "guard"
8
- gem "guard-test"
9
- gem "rails", "3.1.3"
10
- gem "sass-rails"
11
-
12
- group :assets do
13
- gem "compass-rails", :path=>".."
14
- gem "compass-blueprint"
15
- end
16
- group :test do
17
- gem "mocha"
18
- gem "appraisal", :git=>"https://github.com/scottdavis/appraisal.git"
19
- gem "rainbow"
20
- end
21
-
22
- gemspec :path=>"../"
@@ -1,22 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "rb-fsevent", :require=>false
6
- gem "ruby_gntp", :require=>false
7
- gem "guard"
8
- gem "guard-test"
9
- gem "rails", "~> 3.2"
10
- gem "sass-rails"
11
-
12
- group :assets do
13
- gem "compass-rails", :path=>".."
14
- gem "compass-blueprint"
15
- end
16
- group :test do
17
- gem "mocha"
18
- gem "appraisal", :git=>"https://github.com/scottdavis/appraisal.git"
19
- gem "rainbow"
20
- end
21
-
22
- gemspec :path=>"../"
@@ -1,22 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "rb-fsevent", :require=>false
6
- gem "ruby_gntp", :require=>false
7
- gem "guard"
8
- gem "guard-test"
9
- gem "rails", "~> 4.0.0"
10
- gem "sass-rails"
11
-
12
- group :assets do
13
- gem "compass-rails", :path=>".."
14
- gem "compass-blueprint"
15
- end
16
- group :test do
17
- gem "mocha"
18
- gem "appraisal", :git=>"https://github.com/scottdavis/appraisal.git"
19
- gem "rainbow"
20
- end
21
-
22
- gemspec :path=>"../"
@@ -1,30 +0,0 @@
1
- module CompassRails
2
- class Installer < Compass::Installers::ManifestInstaller
3
-
4
- SASS_FILE_REGEX = %r{(.*)(?:\.css)?\.(sass|scss)}
5
-
6
- def completed_configuration
7
- @completed_configuration ||= CompassRails.configuration
8
- end
9
-
10
- def install_stylesheet(from, to, options)
11
- if CompassRails.rails_loaded? && CompassRails.asset_pipeline_enabled?
12
- _, name, ext = SASS_FILE_REGEX.match(to).to_a
13
- to = "#{name}.css.#{ext}"
14
- end
15
- super(from, to, options)
16
- end
17
-
18
- def write_configuration_files
19
- config_file = CompassRails.root.join('config', 'compass.rb')
20
- unless config_file.exist?
21
- write_file config_file.to_s, CompassRails.configuration.serialize
22
- end
23
- end
24
-
25
- def prepare
26
- write_configuration_files
27
- end
28
-
29
- end
30
- end
File without changes
@@ -1,46 +0,0 @@
1
- require 'test_helper'
2
-
3
- class Rails31Test < Test::Unit::TestCase
4
- include CompassRails::Test::RailsHelpers
5
-
6
- RAILS_VERSION = RAILS_3_1
7
-
8
- def test_rails_app_created
9
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
10
- assert project.boots?
11
- end
12
- end
13
-
14
- def test_installs_compass
15
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
16
- project.run_compass('init')
17
- assert project.has_config?
18
- assert project.has_screen_file?
19
- assert project.has_compass_import?
20
- end
21
- end
22
-
23
- def test_compass_compile
24
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
25
- project.run_compass('init')
26
- project.run_compass('compile')
27
- assert project.directory.join('public/assets/screen.css').exist?
28
- end
29
- end
30
-
31
- def test_install_blueprint
32
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
33
- project.run_compass('init')
34
- project.run_compass('install blueprint --force')
35
- assert project.directory.join('app/assets/stylesheets/partials').directory?
36
- end
37
- end
38
-
39
- def test_compass_preferred_syntax
40
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
41
- project.set_rails('sass.preferred_syntax', :sass)
42
- project.run_compass('init')
43
- assert project.directory.join('app/assets/stylesheets/screen.css.sass').exist?
44
- end
45
- end
46
- end
@@ -1,46 +0,0 @@
1
- require 'test_helper'
2
-
3
- class Rails32Test < Test::Unit::TestCase
4
- include CompassRails::Test::RailsHelpers
5
-
6
- RAILS_VERSION = RAILS_3_2
7
-
8
- def test_rails_app_created
9
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
10
- assert project.boots?
11
- end
12
- end
13
-
14
- def test_installs_compass
15
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
16
- project.run_compass('init')
17
- assert project.has_config?
18
- assert project.has_screen_file?
19
- assert project.has_compass_import?
20
- end
21
- end
22
-
23
- def test_compass_compile
24
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
25
- project.run_compass('init')
26
- project.run_compass('compile')
27
- assert project.directory.join('public/assets/screen.css').exist?
28
- end
29
- end
30
-
31
- def test_install_blueprint
32
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
33
- project.run_compass('init')
34
- project.run_compass('install blueprint --force')
35
- assert project.directory.join('app/assets/stylesheets/partials').directory?
36
- end
37
- end
38
-
39
- def test_compass_preferred_syntax
40
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
41
- project.set_rails('sass.preferred_syntax', :sass)
42
- project.run_compass('init')
43
- assert project.directory.join('app/assets/stylesheets/screen.css.sass').exist?
44
- end
45
- end
46
- end
@@ -1,46 +0,0 @@
1
- require 'test_helper'
2
-
3
- class Rails40Test < Test::Unit::TestCase
4
- include CompassRails::Test::RailsHelpers
5
-
6
- RAILS_VERSION = RAILS_4_0
7
-
8
- def test_rails_app_created
9
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
10
- assert project.boots?
11
- end
12
- end
13
-
14
- def test_installs_compass
15
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
16
- project.run_compass('init')
17
- assert project.has_config?
18
- assert project.has_screen_file?
19
- assert project.has_compass_import?
20
- end
21
- end
22
-
23
- def test_compass_compile
24
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
25
- project.run_compass('init')
26
- project.run_compass('compile')
27
- assert project.directory.join('public/assets/screen.css').exist?
28
- end
29
- end
30
-
31
- def test_install_blueprint
32
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
33
- project.run_compass('init')
34
- project.run_compass('install blueprint --force')
35
- assert project.directory.join('app/assets/stylesheets/partials').directory?
36
- end
37
- end
38
-
39
- def test_compass_preferred_syntax
40
- within_rails_app('test_railtie', RAILS_VERSION) do |project|
41
- project.set_rails('sass.preferred_syntax', :sass)
42
- project.run_compass('init')
43
- assert project.directory.join('app/assets/stylesheets/screen.css.sass').exist?
44
- end
45
- end
46
- end
data/test/units/.gitkeep DELETED
File without changes