[Rails] Allow compass extensions to be stored in the vendor/plugins/compass/extensions directory.
This commit is contained in:
parent
0da214a987
commit
51315469d8
20
features/extensions.feature
Normal file
20
features/extensions.feature
Normal file
@ -0,0 +1,20 @@
|
||||
Feature: Extensions
|
||||
In order to have an open source ecosystem for stylesheets
|
||||
As a compass user
|
||||
I can install extensions that others have created
|
||||
And I can create and publish my own extensions
|
||||
|
||||
Scenario: Extensions directory for stand_alone projects
|
||||
Given I am using the existing project in test/fixtures/stylesheets/compass
|
||||
And the "extensions" directory exists
|
||||
And and I have a fake extension at extensions/testing
|
||||
When I run: compass --list-frameworks
|
||||
Then the list of frameworks includes "testing"
|
||||
|
||||
Scenario: Extensions directory for rails projects
|
||||
Given I'm in a newly created rails project: my_rails_project
|
||||
And the "my_rails_project/vendor/plugins/compass/extensions" directory exists
|
||||
And and I have a fake extension at my_rails_project/vendor/plugins/compass/extensions/testing
|
||||
When I run: compass --list-frameworks
|
||||
Then the list of frameworks includes "testing"
|
||||
|
13
features/step_definitions/extension_steps.rb
Normal file
13
features/step_definitions/extension_steps.rb
Normal file
@ -0,0 +1,13 @@
|
||||
Given /^the "([^\"]*)" directory exists$/ do |directory|
|
||||
FileUtils.mkdir_p directory
|
||||
end
|
||||
|
||||
Given /^and I have a fake extension at (.*)$/ do |directory|
|
||||
FileUtils.mkdir_p File.join(directory, 'stylesheets')
|
||||
FileUtils.mkdir_p File.join(directory, 'templates/project')
|
||||
end
|
||||
|
||||
Then /^the list of frameworks includes "([^\"]*)"$/ do |framework|
|
||||
@last_result.split("\n").map{|f| f.strip}.should include(framework)
|
||||
end
|
||||
|
@ -27,6 +27,10 @@ module Compass
|
||||
"/stylesheets"
|
||||
end
|
||||
|
||||
def default_extensions_dir
|
||||
"vendor/plugins/compass/extensions"
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user