Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 45 lines (38 sloc) 1.856 kB
7df97d7 @jferris Added a test for the installation process
jferris authored
1 Feature: Install the Gem in a Rails application
2
3 Background:
4 Given I have built and installed the "hoptoad_notifier" gem
5
1f87891 @jferris Added integration coverage and fixes for older versions of Rails
jferris authored
6 Scenario: Use the gem without vendoring the gem in a Rails application
7df97d7 @jferris Added a test for the installation process
jferris authored
7 When I generate a new Rails application
8 And I configure the Hoptoad shim
9 And I configure my application to require the "hoptoad_notifier" gem
10 And I run "script/generate hoptoad -k myapikey"
11 Then I should receive a Hoptoad notification
022a1a3 @jferris Added scenarios for missing api key/configuring by hand
jferris authored
12
ad3d087 @jferris Changed rake tasks to be included instead of copied
jferris authored
13 Scenario: vendor the gem and uninstall
14 When I generate a new Rails application
15 And I configure the Hoptoad shim
16 And I configure my application to require the "hoptoad_notifier" gem
1f87891 @jferris Added integration coverage and fixes for older versions of Rails
jferris authored
17 And I unpack the "hoptoad_notifier" gem
ad3d087 @jferris Changed rake tasks to be included instead of copied
jferris authored
18 And I run "script/generate hoptoad -k myapikey"
1f87891 @jferris Added integration coverage and fixes for older versions of Rails
jferris authored
19 And I uninstall the "hoptoad_notifier" gem
20 And I run "rake hoptoad:test"
21 Then I should receive two Hoptoad notifications
ad3d087 @jferris Changed rake tasks to be included instead of copied
jferris authored
22
022a1a3 @jferris Added scenarios for missing api key/configuring by hand
jferris authored
23 Scenario: Configure the notifier by hand
24 When I generate a new Rails application
25 And I configure the Hoptoad shim
26 And I configure the notifier to use "myapikey" as an API key
27 And I configure my application to require the "hoptoad_notifier" gem
28 And I run "script/generate hoptoad"
29 Then I should receive a Hoptoad notification
30
31 Scenario: Try to install without an api key
32 When I generate a new Rails application
33 And I configure my application to require the "hoptoad_notifier" gem
34 And I run "script/generate hoptoad"
35 Then I should see "Must pass --api-key or create config/initializers/hoptoad.rb"
2be23d7 @jferris Fixed capistrano recipes
jferris authored
36
37 Scenario: Configure and deploy
38 When I generate a new Rails application
39 And I run "capify ."
40 And I configure the Hoptoad shim
41 And I configure my application to require the "hoptoad_notifier" gem
42 And I run "script/generate hoptoad -k myapikey"
43 And I run "cap -T"
44 Then I should see "deploy:notify_hoptoad"
Something went wrong with that request. Please try again.