2011-12-21 20:11:38 +01:00
|
|
|
Feature: Allow config.rb and extensions to add CLI commands
|
2012-04-17 00:38:26 +02:00
|
|
|
|
|
|
|
Scenario: Command autoloaded from tasks/ directory
|
|
|
|
Given an empty app
|
|
|
|
And a file named "tasks/hello_task.rb" with:
|
|
|
|
"""
|
|
|
|
class Hello < Thor
|
|
|
|
desc "hello", "Say hello"
|
|
|
|
def hello
|
|
|
|
puts "Hello World"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
"""
|
2011-12-21 20:11:38 +01:00
|
|
|
When I run `middleman hello`
|
|
|
|
Then the output should contain "Hello World"
|