simply_mongo 0.0.5 → 0.0.6

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.
Files changed (58) hide show
  1. data/lib/generators/simply_mongo/install/templates/mongo.rb +1 -1
  2. data/lib/generators/simply_mongo/install/templates/mongo.yml +3 -3
  3. data/lib/simply_mongo/version.rb +1 -1
  4. data/test/cmd_line_client/Enterprise.json +30 -0
  5. data/test/cmd_line_client/client.rb +128 -0
  6. data/test/enterprise/Gemfile +45 -0
  7. data/test/enterprise/Gemfile.lock +122 -0
  8. data/test/{dummy → enterprise}/README.rdoc +4 -0
  9. data/test/{dummy → enterprise}/Rakefile +1 -1
  10. data/test/enterprise/app/assets/images/rails.png +0 -0
  11. data/test/{dummy → enterprise}/app/assets/javascripts/application.js +0 -0
  12. data/test/enterprise/app/assets/javascripts/enterprises.js.coffee +3 -0
  13. data/test/{dummy → enterprise}/app/assets/stylesheets/application.css +1 -1
  14. data/test/enterprise/app/assets/stylesheets/enterprises.css.scss +3 -0
  15. data/test/{dummy → enterprise}/app/controllers/application_controller.rb +0 -0
  16. data/test/enterprise/app/controllers/enterprises_controller.rb +62 -0
  17. data/test/{dummy → enterprise}/app/helpers/application_helper.rb +0 -0
  18. data/test/enterprise/app/helpers/enterprises_helper.rb +2 -0
  19. data/test/enterprise/app/views/enterprises/create.html.erb +2 -0
  20. data/test/enterprise/app/views/enterprises/new.html.erb +2 -0
  21. data/test/{dummy → enterprise}/app/views/layouts/application.html.erb +1 -1
  22. data/test/{dummy → enterprise}/config/application.rb +16 -10
  23. data/test/enterprise/config/boot.rb +6 -0
  24. data/test/{dummy → enterprise}/config/environment.rb +1 -1
  25. data/test/{dummy → enterprise}/config/environments/development.rb +1 -7
  26. data/test/{dummy → enterprise}/config/environments/production.rb +2 -5
  27. data/test/{dummy → enterprise}/config/environments/test.rb +1 -3
  28. data/test/{dummy → enterprise}/config/initializers/backtrace_silencers.rb +0 -0
  29. data/test/{dummy/db/test.sqlite3 → enterprise/config/initializers/databases.rb} +0 -0
  30. data/test/{dummy → enterprise}/config/initializers/inflections.rb +0 -0
  31. data/test/{dummy → enterprise}/config/initializers/mime_types.rb +0 -0
  32. data/test/enterprise/config/initializers/mongo.rb +47 -0
  33. data/test/{dummy → enterprise}/config/initializers/secret_token.rb +1 -1
  34. data/test/{dummy → enterprise}/config/initializers/session_store.rb +2 -2
  35. data/test/{dummy → enterprise}/config/initializers/wrap_parameters.rb +2 -5
  36. data/test/{dummy → enterprise}/config/locales/en.yml +0 -0
  37. data/test/enterprise/config/mongo.yml +45 -0
  38. data/test/{dummy → enterprise}/config/routes.rb +10 -1
  39. data/test/{dummy → enterprise}/config.ru +1 -1
  40. data/test/enterprise/db/seeds.rb +7 -0
  41. data/test/enterprise/doc/README_FOR_APP +2 -0
  42. data/test/enterprise/log/development.log +968 -0
  43. data/test/{dummy → enterprise}/public/404.html +0 -0
  44. data/test/{dummy → enterprise}/public/422.html +0 -0
  45. data/test/{dummy → enterprise}/public/500.html +0 -0
  46. data/test/{dummy → enterprise}/public/favicon.ico +0 -0
  47. data/test/enterprise/public/index.html +241 -0
  48. data/test/enterprise/public/robots.txt +5 -0
  49. data/test/{dummy → enterprise}/script/rails +0 -0
  50. data/test/enterprise/tmp/cache/assets/CF0/DA0/sprockets%2Fd7d5b37686831d37c4dd75e645f5e016 +0 -0
  51. data/test/enterprise/tmp/cache/assets/E25/4C0/sprockets%2Fde2fd9fd11c04a582cdbbe3d84a35ae6 +0 -0
  52. data/test/enterprise/tmp/pids/server.pid +1 -0
  53. metadata +100 -67
  54. data/test/dummy/config/boot.rb +0 -10
  55. data/test/dummy/config/database.yml +0 -25
  56. data/test/dummy/log/test.log +0 -3
  57. data/test/simply_mongo_test.rb +0 -7
  58. data/test/test_helper.rb +0 -15
@@ -4,4 +4,4 @@
4
4
  # If you change this key, all old signed cookies will become invalid!
5
5
  # Make sure the secret is at least 30 characters and all random,
6
6
  # no regular words or you'll be exposed to dictionary attacks.
7
- Dummy::Application.config.secret_token = '0dfbd4d8f5e6daeb608849bbb3ce79d38798a172a75a04d37f7277d448c809b97a08ed0d8d8b63158c1382812137548848bc982b8013f9fdd24701938867af4a'
7
+ Enterprise::Application.config.secret_token = '6ebe0b6241b8eaa39dd5116ff06f52c4596520a8c5edfcc42089366c2387020e41032ed5ef2e5bacaeedf8036ceb2447ea569be8418f809199fe32855ad8474c'
@@ -1,8 +1,8 @@
1
1
  # Be sure to restart your server when you modify this file.
2
2
 
3
- Dummy::Application.config.session_store :cookie_store, key: '_dummy_session'
3
+ Enterprise::Application.config.session_store :cookie_store, key: '_enterprise_session'
4
4
 
5
5
  # Use the database for sessions instead of the cookie-based default,
6
6
  # which shouldn't be used to store highly confidential information
7
7
  # (create the session table with "rails generate session_migration")
8
- # Dummy::Application.config.session_store :active_record_store
8
+ # Enterprise::Application.config.session_store :active_record_store
@@ -5,10 +5,7 @@
5
5
 
6
6
  # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
7
7
  ActiveSupport.on_load(:action_controller) do
8
- wrap_parameters format: [:json]
8
+ #wrap_parameters format: [:json]
9
+ wrap_parameters format: []
9
10
  end
10
11
 
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,45 @@
1
+ #------------------------------------------------------------------------------------------------------------------------------------------------
2
+ # Simply Mongo Driver Specification
3
+ #
4
+ # OPTIONS:
5
+ # :safe (Boolean, Hash) — default: false — Set the default safe-mode options propogated to
6
+ # DB objects instantiated off of this Connection. This default can
7
+ # be overridden upon instantiation of any DB by explicity setting a :safe value on initialization.
8
+ # :slave_ok (Boolean) — default: false — Must be set to true when connecting to a single, slave node.
9
+ # :logger (Logger, #debug) — default: nil — A Logger instance for debugging driver ops.
10
+ # Note that logging negatively impacts performance; therefore, it should not be
11
+ # used for high-performance apps.
12
+ # :pool_size (Integer) — default: 1 — The maximum number of socket self.connections allowed per connection pool. Note: this
13
+ # setting is relevant only for multi-threaded applications.
14
+ # :timeout (Float) — default: 5.0 — When all of the self.connections a pool are checked out, this is the number of seconds
15
+ # to wait for a new connection to be released before throwing an exception. Note: this
16
+ # setting is relevant only for multi-threaded applications (which in Ruby are rare).
17
+ # :op_timeout (Float) — default: nil — The number of seconds to wait for a read operation to time out. Disabled by default.
18
+ # :connect_timeout (Float) — default: nil — The number of seconds to wait before timing out a connection attempt.
19
+ # :ssl (Boolean) — default: false — If true, create the connection to the server using SSL.
20
+ #------------------------------------------------------------------------------------------------------------------------------------------------
21
+
22
+ development:
23
+ adapter: mongodb
24
+ database: dyntech-dev
25
+ host: localhost
26
+ port: 27017
27
+ options:
28
+ safe: true
29
+
30
+
31
+ test:
32
+ adapter: mongodb
33
+ database: dyntech-test
34
+ host: localhost
35
+ port: 27017
36
+ options:
37
+ safe: true
38
+
39
+ production:
40
+ adapter: mongodb
41
+ database: dyntech
42
+ host: localhost
43
+ port: 27017
44
+ options:
45
+ safe: true
@@ -1,4 +1,13 @@
1
- Dummy::Application.routes.draw do
1
+ Enterprise::Application.routes.draw do
2
+ #resources :enterprises, only: [:new, :create, :update, :show, :destroy]
3
+ get "enterprises" => "enterprises#index"
4
+ get "enterprises/new"
5
+ post "enterprises/create"
6
+ get "enterprises/:id" => "enterprises#show"
7
+ put "enterprises/:id" => "enterprises#update"
8
+ delete "enterprises/:id" => "enterprises#destroy"
9
+
10
+
2
11
  # The priority is based upon order of creation:
3
12
  # first created -> highest priority.
4
13
 
@@ -1,4 +1,4 @@
1
1
  # This file is used by Rack-based servers to start the application.
2
2
 
3
3
  require ::File.expand_path('../config/environment', __FILE__)
4
- run Dummy::Application
4
+ run Enterprise::Application
@@ -0,0 +1,7 @@
1
+ # This file should contain all the record creation needed to seed the database with its default values.
2
+ # The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).
3
+ #
4
+ # Examples:
5
+ #
6
+ # cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])
7
+ # Mayor.create(name: 'Emanuel', city: cities.first)
@@ -0,0 +1,2 @@
1
+ Use this README file to introduce your application and point to useful places in the API for learning more.
2
+ Run "rake doc:app" to generate API documentation for your models, controllers, helpers, and libraries.