datastore_mongo 0.0.1
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.
- data/MIT-LICENSE +20 -0
- data/README.rdoc +3 -0
- data/Rakefile +39 -0
- data/app/assets/javascripts/datastore_mongo/application.js +9 -0
- data/app/assets/javascripts/datastore_mongo/mongo_strings.js +2 -0
- data/app/assets/stylesheets/datastore_mongo/application.css +7 -0
- data/app/assets/stylesheets/datastore_mongo/mongo_strings.css +4 -0
- data/app/assets/stylesheets/scaffold.css +56 -0
- data/app/controllers/datastore_mongo/application_controller.rb +4 -0
- data/app/controllers/datastore_mongo/mongo_strings_controller.rb +85 -0
- data/app/helpers/datastore_mongo/application_helper.rb +4 -0
- data/app/helpers/datastore_mongo/mongo_strings_helper.rb +4 -0
- data/app/models/datastore_mongo/mongo_string.rb +7 -0
- data/app/views/datastore_mongo/mongo_strings/_form.html.erb +25 -0
- data/app/views/datastore_mongo/mongo_strings/edit.html.erb +6 -0
- data/app/views/datastore_mongo/mongo_strings/index.html.erb +25 -0
- data/app/views/datastore_mongo/mongo_strings/new.html.erb +5 -0
- data/app/views/datastore_mongo/mongo_strings/show.html.erb +15 -0
- data/app/views/layouts/datastore_mongo/application.html.erb +14 -0
- data/config/initializers/mongo.rb +11 -0
- data/config/routes.rb +4 -0
- data/lib/datastore_mongo/engine.rb +5 -0
- data/lib/datastore_mongo/version.rb +3 -0
- data/lib/datastore_mongo.rb +4 -0
- data/lib/tasks/datastore_mongo_tasks.rake +4 -0
- data/test/datastore_mongo_test.rb +7 -0
- data/test/dummy/Rakefile +7 -0
- data/test/dummy/app/assets/javascripts/application.js +9 -0
- data/test/dummy/app/assets/stylesheets/application.css +7 -0
- data/test/dummy/app/controllers/application_controller.rb +3 -0
- data/test/dummy/app/helpers/application_helper.rb +2 -0
- data/test/dummy/app/views/layouts/application.html.erb +14 -0
- data/test/dummy/config/application.rb +45 -0
- data/test/dummy/config/boot.rb +10 -0
- data/test/dummy/config/database.yml +25 -0
- data/test/dummy/config/environment.rb +5 -0
- data/test/dummy/config/environments/development.rb +30 -0
- data/test/dummy/config/environments/production.rb +60 -0
- data/test/dummy/config/environments/test.rb +39 -0
- data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/test/dummy/config/initializers/inflections.rb +10 -0
- data/test/dummy/config/initializers/mime_types.rb +5 -0
- data/test/dummy/config/initializers/secret_token.rb +7 -0
- data/test/dummy/config/initializers/session_store.rb +8 -0
- data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/test/dummy/config/locales/en.yml +5 -0
- data/test/dummy/config/routes.rb +4 -0
- data/test/dummy/config.ru +4 -0
- data/test/dummy/db/development.sqlite3 +0 -0
- data/test/dummy/log/development.log +303 -0
- data/test/dummy/public/404.html +26 -0
- data/test/dummy/public/422.html +26 -0
- data/test/dummy/public/500.html +26 -0
- data/test/dummy/public/favicon.ico +0 -0
- data/test/dummy/script/rails +6 -0
- data/test/dummy/tmp/cache/assets/C79/FE0/sprockets%2F60c98361f2b98f8123dc3220763b1b07 +0 -0
- data/test/dummy/tmp/cache/assets/CB5/660/sprockets%2F4828404ba37f9402349bef0e918e0c67 +0 -0
- data/test/dummy/tmp/cache/assets/CE2/DF0/sprockets%2Fe389db18b89c773c05fa64f243251b14 +0 -0
- data/test/dummy/tmp/cache/assets/CEA/A80/sprockets%2Fe68d6a00959556532e92b70c56edb3b8 +0 -0
- data/test/dummy/tmp/cache/assets/CFD/F60/sprockets%2F0f40317a6babb81870b036af43d6d447 +0 -0
- data/test/dummy/tmp/cache/assets/CFE/F10/sprockets%2F9988fc39a760525719d57fa2751efcc9 +0 -0
- data/test/dummy/tmp/cache/assets/D18/740/sprockets%2F6cf782d157c833aafe2e6132b86e4476 +0 -0
- data/test/dummy/tmp/cache/assets/D1F/430/sprockets%2Fd90216589ab4ead84b26d4628f88b8b6 +0 -0
- data/test/dummy/tmp/cache/assets/D3C/550/sprockets%2F085759d3bb472fea26d0d3bf2a8813e3 +0 -0
- data/test/dummy/tmp/cache/assets/D45/0B0/sprockets%2Fb6fb348130590989cecd0f7bcf3c8621 +0 -0
- data/test/dummy/tmp/cache/assets/D46/5C0/sprockets%2F63820178fa5358b3e9206aadfc66e5fe +0 -0
- data/test/dummy/tmp/cache/assets/D98/0C0/sprockets%2F122a68de8c1c103dca5f83da769f5e1b +0 -0
- data/test/fixtures/datastore_mongo/mongo_strings.yml +9 -0
- data/test/functional/datastore_mongo/mongo_strings_controller_test.rb +51 -0
- data/test/integration/navigation_test.rb +10 -0
- data/test/test_helper.rb +10 -0
- data/test/unit/datastore_mongo/mongo_string_test.rb +9 -0
- data/test/unit/helpers/datastore_mongo/mongo_strings_helper_test.rb +6 -0
- metadata +205 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
Dummy::Application.configure do
|
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb
|
|
3
|
+
|
|
4
|
+
# The test environment is used exclusively to run your application's
|
|
5
|
+
# test suite. You never need to work with it otherwise. Remember that
|
|
6
|
+
# your test database is "scratch space" for the test suite and is wiped
|
|
7
|
+
# and recreated between test runs. Don't rely on the data there!
|
|
8
|
+
config.cache_classes = true
|
|
9
|
+
|
|
10
|
+
# Configure static asset server for tests with Cache-Control for performance
|
|
11
|
+
config.serve_static_assets = true
|
|
12
|
+
config.static_cache_control = "public, max-age=3600"
|
|
13
|
+
|
|
14
|
+
# Log error messages when you accidentally call methods on nil
|
|
15
|
+
config.whiny_nils = true
|
|
16
|
+
|
|
17
|
+
# Show full error reports and disable caching
|
|
18
|
+
config.consider_all_requests_local = true
|
|
19
|
+
config.action_controller.perform_caching = false
|
|
20
|
+
|
|
21
|
+
# Raise exceptions instead of rendering exception templates
|
|
22
|
+
config.action_dispatch.show_exceptions = false
|
|
23
|
+
|
|
24
|
+
# Disable request forgery protection in test environment
|
|
25
|
+
config.action_controller.allow_forgery_protection = false
|
|
26
|
+
|
|
27
|
+
# Tell Action Mailer not to deliver emails to the real world.
|
|
28
|
+
# The :test delivery method accumulates sent emails in the
|
|
29
|
+
# ActionMailer::Base.deliveries array.
|
|
30
|
+
config.action_mailer.delivery_method = :test
|
|
31
|
+
|
|
32
|
+
# Use SQL instead of Active Record's schema dumper when creating the test database.
|
|
33
|
+
# This is necessary if your schema can't be completely dumped by the schema dumper,
|
|
34
|
+
# like if you have constraints or database-specific column types
|
|
35
|
+
# config.active_record.schema_format = :sql
|
|
36
|
+
|
|
37
|
+
# Print deprecation notices to the stderr
|
|
38
|
+
config.active_support.deprecation = :stderr
|
|
39
|
+
end
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
|
2
|
+
|
|
3
|
+
# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.
|
|
4
|
+
# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }
|
|
5
|
+
|
|
6
|
+
# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.
|
|
7
|
+
# Rails.backtrace_cleaner.remove_silencers!
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
|
2
|
+
|
|
3
|
+
# Add new inflection rules using the following format
|
|
4
|
+
# (all these examples are active by default):
|
|
5
|
+
# ActiveSupport::Inflector.inflections do |inflect|
|
|
6
|
+
# inflect.plural /^(ox)$/i, '\1en'
|
|
7
|
+
# inflect.singular /^(ox)en/i, '\1'
|
|
8
|
+
# inflect.irregular 'person', 'people'
|
|
9
|
+
# inflect.uncountable %w( fish sheep )
|
|
10
|
+
# end
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
|
2
|
+
|
|
3
|
+
# Your secret key for verifying the integrity of signed cookies.
|
|
4
|
+
# If you change this key, all old signed cookies will become invalid!
|
|
5
|
+
# Make sure the secret is at least 30 characters and all random,
|
|
6
|
+
# no regular words or you'll be exposed to dictionary attacks.
|
|
7
|
+
Dummy::Application.config.secret_token = 'd0c4ec2d40b6cb9fa61c912d1be7af2c301c3a15e24f4c4f0545c641505b198b71909af40e041dfcae57a61447b31c9b16311a17a8712c2626e27e295767341a'
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
|
2
|
+
|
|
3
|
+
Dummy::Application.config.session_store :cookie_store, key: '_dummy_session'
|
|
4
|
+
|
|
5
|
+
# Use the database for sessions instead of the cookie-based default,
|
|
6
|
+
# which shouldn't be used to store highly confidential information
|
|
7
|
+
# (create the session table with "rails generate session_migration")
|
|
8
|
+
# Dummy::Application.config.session_store :active_record_store
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
|
2
|
+
#
|
|
3
|
+
# This file contains settings for ActionController::ParamsWrapper which
|
|
4
|
+
# is enabled by default.
|
|
5
|
+
|
|
6
|
+
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
|
7
|
+
ActiveSupport.on_load(:action_controller) do
|
|
8
|
+
wrap_parameters format: [:json]
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
# Disable root element in JSON by default.
|
|
12
|
+
ActiveSupport.on_load(:active_record) do
|
|
13
|
+
self.include_root_in_json = false
|
|
14
|
+
end
|
|
File without changes
|
|
@@ -0,0 +1,303 @@
|
|
|
1
|
+
|
|
2
|
+
|
|
3
|
+
Started GET "/" for 127.0.0.1 at 2011-11-14 18:04:39 -0800
|
|
4
|
+
|
|
5
|
+
ActionController::RoutingError (No route matches [GET] "/"):
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
Rendered /Users/MacbookPro/.rvm/gems/ruby-1.9.2-p290@datastores/gems/actionpack-3.1.1/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (88.5ms)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:04:49 -0800
|
|
12
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
13
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (2.3ms)
|
|
14
|
+
Compiled datastore_mongo/application.css (2ms) (pid 675)
|
|
15
|
+
Compiled datastore_mongo/mongo_strings.css (0ms) (pid 675)
|
|
16
|
+
Compiled datastore_mongo/application.js (9ms) (pid 675)
|
|
17
|
+
Compiled jquery.js (10ms) (pid 675)
|
|
18
|
+
Compiled jquery_ujs.js (1ms) (pid 675)
|
|
19
|
+
Compiled datastore_mongo/mongo_strings.js (0ms) (pid 675)
|
|
20
|
+
Completed 200 OK in 260ms (Views: 257.0ms | ActiveRecord: 0.0ms)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
Started GET "/assets/datastore_mongo/mongo_strings.css?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
24
|
+
Served asset /datastore_mongo/mongo_strings.css - 200 OK (30ms)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
Started GET "/assets/datastore_mongo/application.css?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
28
|
+
Served asset /datastore_mongo/application.css - 200 OK (0ms)
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
32
|
+
Served asset /jquery.js - 304 Not Modified (7ms)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
Started GET "/assets/datastore_mongo/mongo_strings.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
36
|
+
Served asset /datastore_mongo/mongo_strings.js - 200 OK (5ms)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
40
|
+
Served asset /jquery_ujs.js - 304 Not Modified (4ms)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
Started GET "/assets/datastore_mongo/application.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:50 -0800
|
|
44
|
+
Served asset /datastore_mongo/application.js - 200 OK (0ms)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
Started GET "/datastore_mongo/mongo_strings/new" for 127.0.0.1 at 2011-11-14 18:04:53 -0800
|
|
48
|
+
Processing by DatastoreMongo::MongoStringsController#new as HTML
|
|
49
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/_form.html.erb (8.6ms)
|
|
50
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/new.html.erb within layouts/datastore_mongo/application (30.0ms)
|
|
51
|
+
Completed 200 OK in 44ms (Views: 42.9ms | ActiveRecord: 0.0ms)
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:53 -0800
|
|
55
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:04:54 -0800
|
|
59
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
Started POST "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:09 -0800
|
|
63
|
+
Processing by DatastoreMongo::MongoStringsController#create as HTML
|
|
64
|
+
Parameters: {"utf8"=>"✓", "authenticity_token"=>"2CrGVleqS8+Y/DWeODUaJv5vUjpugXRM6MIC0VkTp6U=", "mongo_string"=>{"field_1"=>"Field value 1", "field_2"=>"field value 2"}, "commit"=>"Create Mongo string"}
|
|
65
|
+
Redirected to http://localhost:3000/datastore_mongo/mongo_strings/4ec1c8d575f6a902a3000001
|
|
66
|
+
Completed 302 Found in 5ms
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
Started GET "/datastore_mongo/mongo_strings/4ec1c8d575f6a902a3000001" for 127.0.0.1 at 2011-11-14 18:05:09 -0800
|
|
70
|
+
Processing by DatastoreMongo::MongoStringsController#show as HTML
|
|
71
|
+
Parameters: {"id"=>"4ec1c8d575f6a902a3000001"}
|
|
72
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/show.html.erb within layouts/datastore_mongo/application (3.3ms)
|
|
73
|
+
Completed 200 OK in 21ms (Views: 17.9ms | ActiveRecord: 0.0ms)
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:10 -0800
|
|
77
|
+
Served asset /jquery.js - 304 Not Modified (8ms)
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:10 -0800
|
|
81
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:11 -0800
|
|
85
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
86
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (6.0ms)
|
|
87
|
+
Completed 200 OK in 27ms (Views: 24.4ms | ActiveRecord: 0.0ms)
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:12 -0800
|
|
91
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:12 -0800
|
|
95
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
Started GET "/datastore_mongo/mongo_strings/new" for 127.0.0.1 at 2011-11-14 18:05:16 -0800
|
|
99
|
+
Processing by DatastoreMongo::MongoStringsController#new as HTML
|
|
100
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/_form.html.erb (8.5ms)
|
|
101
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/new.html.erb within layouts/datastore_mongo/application (10.6ms)
|
|
102
|
+
Completed 200 OK in 26ms (Views: 25.6ms | ActiveRecord: 0.0ms)
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:16 -0800
|
|
106
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:16 -0800
|
|
110
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
Started POST "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:20 -0800
|
|
114
|
+
Processing by DatastoreMongo::MongoStringsController#create as HTML
|
|
115
|
+
Parameters: {"utf8"=>"✓", "authenticity_token"=>"2CrGVleqS8+Y/DWeODUaJv5vUjpugXRM6MIC0VkTp6U=", "mongo_string"=>{"field_1"=>"dope", "field_2"=>"man"}, "commit"=>"Create Mongo string"}
|
|
116
|
+
Redirected to http://localhost:3000/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004
|
|
117
|
+
Completed 302 Found in 4ms
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
Started GET "/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004" for 127.0.0.1 at 2011-11-14 18:05:20 -0800
|
|
121
|
+
Processing by DatastoreMongo::MongoStringsController#show as HTML
|
|
122
|
+
Parameters: {"id"=>"4ec1c8e075f6a902a3000004"}
|
|
123
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/show.html.erb within layouts/datastore_mongo/application (1.9ms)
|
|
124
|
+
Completed 200 OK in 20ms (Views: 16.9ms | ActiveRecord: 0.0ms)
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:20 -0800
|
|
128
|
+
Served asset /jquery_ujs.js - 304 Not Modified (1ms)
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:20 -0800
|
|
132
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:21 -0800
|
|
136
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:24 -0800
|
|
140
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
141
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (8.6ms)
|
|
142
|
+
Completed 200 OK in 72ms (Views: 68.8ms | ActiveRecord: 0.0ms)
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:24 -0800
|
|
146
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:24 -0800
|
|
150
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
Started DELETE "/datastore_mongo/mongo_strings/4ec1c8d575f6a902a3000001" for 127.0.0.1 at 2011-11-14 18:05:28 -0800
|
|
154
|
+
Processing by DatastoreMongo::MongoStringsController#destroy as HTML
|
|
155
|
+
Parameters: {"authenticity_token"=>"2CrGVleqS8+Y/DWeODUaJv5vUjpugXRM6MIC0VkTp6U=", "id"=>"4ec1c8d575f6a902a3000001"}
|
|
156
|
+
Redirected to http://localhost:3000/datastore_mongo/mongo_strings
|
|
157
|
+
Completed 302 Found in 5ms
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:28 -0800
|
|
161
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
162
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (10.8ms)
|
|
163
|
+
Completed 200 OK in 30ms (Views: 27.5ms | ActiveRecord: 0.0ms)
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:28 -0800
|
|
167
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:28 -0800
|
|
171
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:29 -0800
|
|
175
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
Started GET "/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004/edit" for 127.0.0.1 at 2011-11-14 18:05:31 -0800
|
|
179
|
+
Processing by DatastoreMongo::MongoStringsController#edit as HTML
|
|
180
|
+
Parameters: {"id"=>"4ec1c8e075f6a902a3000004"}
|
|
181
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/_form.html.erb (6.8ms)
|
|
182
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/edit.html.erb within layouts/datastore_mongo/application (11.0ms)
|
|
183
|
+
Completed 200 OK in 32ms (Views: 28.4ms | ActiveRecord: 0.0ms)
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:31 -0800
|
|
187
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:31 -0800
|
|
191
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
Started PUT "/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004" for 127.0.0.1 at 2011-11-14 18:05:33 -0800
|
|
195
|
+
Processing by DatastoreMongo::MongoStringsController#update as HTML
|
|
196
|
+
Parameters: {"utf8"=>"✓", "authenticity_token"=>"2CrGVleqS8+Y/DWeODUaJv5vUjpugXRM6MIC0VkTp6U=", "mongo_string"=>{"field_1"=>"dope", "field_2"=>"man1"}, "commit"=>"Update Mongo string", "id"=>"4ec1c8e075f6a902a3000004"}
|
|
197
|
+
Redirected to http://localhost:3000/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004
|
|
198
|
+
Completed 302 Found in 9ms
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
Started GET "/datastore_mongo/mongo_strings/4ec1c8e075f6a902a3000004" for 127.0.0.1 at 2011-11-14 18:05:33 -0800
|
|
202
|
+
Processing by DatastoreMongo::MongoStringsController#show as HTML
|
|
203
|
+
Parameters: {"id"=>"4ec1c8e075f6a902a3000004"}
|
|
204
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/show.html.erb within layouts/datastore_mongo/application (3.1ms)
|
|
205
|
+
Completed 200 OK in 30ms (Views: 26.4ms | ActiveRecord: 0.0ms)
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:33 -0800
|
|
209
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
210
|
+
|
|
211
|
+
|
|
212
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:33 -0800
|
|
213
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
214
|
+
|
|
215
|
+
|
|
216
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:33 -0800
|
|
217
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
218
|
+
|
|
219
|
+
|
|
220
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:05:36 -0800
|
|
221
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
222
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (48.5ms)
|
|
223
|
+
Completed 200 OK in 68ms (Views: 65.3ms | ActiveRecord: 0.0ms)
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:36 -0800
|
|
227
|
+
Served asset /jquery.js - 304 Not Modified (0ms)
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:05:36 -0800
|
|
231
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:08:56 -0800
|
|
235
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
236
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (77.0ms)
|
|
237
|
+
Completed 200 OK in 197ms (Views: 194.2ms | ActiveRecord: 0.0ms)
|
|
238
|
+
|
|
239
|
+
|
|
240
|
+
Started GET "/assets/datastore_mongo/mongo_strings.css?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
241
|
+
Served asset /datastore_mongo/mongo_strings.css - 304 Not Modified (10ms)
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
245
|
+
Served asset /jquery_ujs.js - 304 Not Modified (5ms)
|
|
246
|
+
|
|
247
|
+
|
|
248
|
+
Started GET "/assets/datastore_mongo/application.css?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
249
|
+
Served asset /datastore_mongo/application.css - 304 Not Modified (0ms)
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
253
|
+
Served asset /jquery.js - 304 Not Modified (9ms)
|
|
254
|
+
|
|
255
|
+
|
|
256
|
+
Started GET "/assets/datastore_mongo/mongo_strings.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
257
|
+
Served asset /datastore_mongo/mongo_strings.js - 304 Not Modified (16ms)
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
Started GET "/assets/datastore_mongo/application.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
261
|
+
Served asset /datastore_mongo/application.js - 304 Not Modified (0ms)
|
|
262
|
+
|
|
263
|
+
|
|
264
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
265
|
+
Served asset /jquery_ujs.js - 304 Not Modified (0ms)
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
Started GET "/assets/datastore_mongo/mongo_strings.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:58 -0800
|
|
269
|
+
Served asset /datastore_mongo/mongo_strings.js - 304 Not Modified (0ms)
|
|
270
|
+
|
|
271
|
+
|
|
272
|
+
Started GET "/assets/datastore_mongo/application.js?body=1" for 127.0.0.1 at 2011-11-14 18:08:59 -0800
|
|
273
|
+
Served asset /datastore_mongo/application.js - 304 Not Modified (0ms)
|
|
274
|
+
|
|
275
|
+
|
|
276
|
+
Started GET "/datastore_mongo/mongo_strings" for 127.0.0.1 at 2011-11-14 18:09:28 -0800
|
|
277
|
+
Processing by DatastoreMongo::MongoStringsController#index as HTML
|
|
278
|
+
Rendered /workspace/thinknear/datastore_mongo/app/views/datastore_mongo/mongo_strings/index.html.erb within layouts/datastore_mongo/application (80.4ms)
|
|
279
|
+
Completed 200 OK in 207ms (Views: 202.2ms | ActiveRecord: 0.0ms)
|
|
280
|
+
|
|
281
|
+
|
|
282
|
+
Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
283
|
+
Served asset /jquery_ujs.js - 304 Not Modified (3ms)
|
|
284
|
+
|
|
285
|
+
|
|
286
|
+
Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
287
|
+
Served asset /jquery.js - 304 Not Modified (5ms)
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
Started GET "/assets/datastore_mongo/mongo_strings.js?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
291
|
+
Served asset /datastore_mongo/mongo_strings.js - 304 Not Modified (5ms)
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
Started GET "/assets/datastore_mongo/mongo_strings.css?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
295
|
+
Served asset /datastore_mongo/mongo_strings.css - 304 Not Modified (7ms)
|
|
296
|
+
|
|
297
|
+
|
|
298
|
+
Started GET "/assets/datastore_mongo/application.js?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
299
|
+
Served asset /datastore_mongo/application.js - 304 Not Modified (0ms)
|
|
300
|
+
|
|
301
|
+
|
|
302
|
+
Started GET "/assets/datastore_mongo/application.css?body=1" for 127.0.0.1 at 2011-11-14 18:09:30 -0800
|
|
303
|
+
Served asset /datastore_mongo/application.css - 304 Not Modified (0ms)
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>The page you were looking for doesn't exist (404)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/404.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>The page you were looking for doesn't exist.</h1>
|
|
23
|
+
<p>You may have mistyped the address or the page may have moved.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>The change you wanted was rejected (422)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/422.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>The change you wanted was rejected.</h1>
|
|
23
|
+
<p>Maybe you tried to change something you didn't have access to.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>We're sorry, but something went wrong (500)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/500.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>We're sorry, but something went wrong.</h1>
|
|
23
|
+
<p>We've been notified about this issue and we'll take a look at it shortly.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
|
File without changes
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
#!/usr/bin/env ruby
|
|
2
|
+
# This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
|
|
3
|
+
|
|
4
|
+
APP_PATH = File.expand_path('../../config/application', __FILE__)
|
|
5
|
+
require File.expand_path('../../config/boot', __FILE__)
|
|
6
|
+
require 'rails/commands'
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
require 'test_helper'
|
|
2
|
+
|
|
3
|
+
module DatastoreMongo
|
|
4
|
+
class MongoStringsControllerTest < ActionController::TestCase
|
|
5
|
+
setup do
|
|
6
|
+
@mongo_string = mongo_strings(:one)
|
|
7
|
+
end
|
|
8
|
+
|
|
9
|
+
test "should get index" do
|
|
10
|
+
get :index
|
|
11
|
+
assert_response :success
|
|
12
|
+
assert_not_nil assigns(:mongo_strings)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
test "should get new" do
|
|
16
|
+
get :new
|
|
17
|
+
assert_response :success
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
test "should create mongo_string" do
|
|
21
|
+
assert_difference('MongoString.count') do
|
|
22
|
+
post :create, mongo_string: @mongo_string.attributes
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
assert_redirected_to mongo_string_path(assigns(:mongo_string))
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
test "should show mongo_string" do
|
|
29
|
+
get :show, id: @mongo_string.to_param
|
|
30
|
+
assert_response :success
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
test "should get edit" do
|
|
34
|
+
get :edit, id: @mongo_string.to_param
|
|
35
|
+
assert_response :success
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
test "should update mongo_string" do
|
|
39
|
+
put :update, id: @mongo_string.to_param, mongo_string: @mongo_string.attributes
|
|
40
|
+
assert_redirected_to mongo_string_path(assigns(:mongo_string))
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
test "should destroy mongo_string" do
|
|
44
|
+
assert_difference('MongoString.count', -1) do
|
|
45
|
+
delete :destroy, id: @mongo_string.to_param
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
assert_redirected_to mongo_strings_path
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
end
|
data/test/test_helper.rb
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# Configure Rails Environment
|
|
2
|
+
ENV["RAILS_ENV"] = "test"
|
|
3
|
+
|
|
4
|
+
require File.expand_path("../dummy/config/environment.rb", __FILE__)
|
|
5
|
+
require "rails/test_help"
|
|
6
|
+
|
|
7
|
+
Rails.backtrace_cleaner.remove_silencers!
|
|
8
|
+
|
|
9
|
+
# Load support files
|
|
10
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|