Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 373
- Log:
Initial import of Radiant 0.9.1, which is now packaged as a gem. This is an
import of the tagged 0.9.1 source checked out from GitHub, which isn't quite
the same as the gem distribution - but it doesn't seem to be available in an
archived form and the installed gem already has modifications, so this is
the closest I can get.
- Author:
- rool
- Date:
- Mon Mar 21 13:40:05 +0000 2011
- Size:
- 2449 Bytes
1 | require File.dirname(__FILE__) + "/extension_generators_spec_helper" |
2 | |
3 | describe "ExtensionMailerGenerator with normal options" do |
4 | it_should_behave_like AllGenerators |
5 | it_should_behave_like AllExtensionGenerators |
6 | |
7 | before(:each) do |
8 | cp_r File.join(BASE_ROOT, 'lib/generators/extension_mailer'), File.join(RADIANT_ROOT, 'vendor/generators') |
9 | run_generator('extension_mailer', %w(example SignupNotifications thankyou)) |
10 | end |
11 | |
12 | it 'should generate the model file in the correct location' do |
13 | 'vendor/extensions/example'.should have_generated_model_for('SignupNotifications', 'ActionMailer::Base') |
14 | end |
15 | |
16 | it 'should generate the view file in the correct location' do |
17 | 'vendor/extensions/example'.should have_generated_view_for('SignupNotifications', 'thankyou', 'erb') |
18 | end |
19 | |
20 | after(:each) do |
21 | extension_dir = File.join(RADIANT_ROOT, 'vendor/extensions/example') |
22 | rm_rf Dir["#{extension_dir}/app/models/*"] |
23 | rm_rf Dir["#{extension_dir}/app/views/*"] |
24 | rm_rf Dir["#{RADIANT_ROOT}/vendor/generators/*"] |
25 | end |
26 | end |
27 | |
28 | describe "ExtensionMailerGenerator with test unit" do |
29 | it_should_behave_like AllGenerators |
30 | it_should_behave_like AllExtensionGenerators |
31 | |
32 | before(:each) do |
33 | cp_r File.join(BASE_ROOT, 'lib/generators/extension_mailer'), File.join(RADIANT_ROOT, 'vendor/generators') |
34 | run_generator('extension_mailer', %w(example SignupNotifications thankyou --with-test-unit)) |
35 | end |
36 | |
37 | it 'should generate the model file in the correct location' do |
38 | 'vendor/extensions/example'.should have_generated_model_for('SignupNotifications', 'ActionMailer::Base') |
39 | end |
40 | |
41 | it 'should generate the view file in the correct location' do |
42 | 'vendor/extensions/example'.should have_generated_view_for('SignupNotifications', 'thankyou', 'erb') |
43 | end |
44 | |
45 | it 'should generate the unit test file in the correct location' do |
46 | 'vendor/extensions/example'.should have_generated_unit_test_for('SignupNotifications', 'ActionMailer::TestCase') |
47 | end |
48 | |
49 | it 'should generate the fixture file in the correct location' do |
50 | 'vendor/extensions/example'.should have_generated_file('test/fixtures/signup_notifications/thankyou') |
51 | end |
52 | |
53 | after(:each) do |
54 | extension_dir = File.join(RADIANT_ROOT, 'vendor/extensions/example') |
55 | rm_rf Dir["#{extension_dir}/app/models/*"] |
56 | rm_rf Dir["#{extension_dir}/app/views/*"] |
57 | rm_rf Dir["#{RADIANT_ROOT}/vendor/generators/*"] |
58 | rm_rf Dir["#{extension_dir}/test/*"] |
59 | end |
60 | end |