From 9c169afa8d8c9481ba031d60d79adcd68f5ac459 Mon Sep 17 00:00:00 2001 From: Antonio C Nalesso Moreira Date: Thu, 11 Jul 2013 03:11:26 +0100 Subject: [PATCH] added tests folder, changed Rakefile, impressionist.gemspec --- Rakefile | 5 +- impressionist.gemspec | 7 +- spec/spec_helper.rb | 5 -- tests/README | 1 + {test_app => tests/test_app}/.gitignore | 0 {test_app => tests/test_app}/.rspec | 0 {test_app => tests/test_app}/Gemfile | 0 {test_app => tests/test_app}/README | 0 {test_app => tests/test_app}/README.rdoc | 0 {test_app => tests/test_app}/Rakefile | 0 .../test_app}/app/assets/images/rails.png | Bin .../app/assets/javascripts/application.js | 0 .../app/assets/stylesheets/application.css | 0 .../app/controllers/application_controller.rb | 0 .../app/controllers/articles_controller.rb | 0 .../app/controllers/dummy_controller.rb | 0 .../app/controllers/posts_controller.rb | 0 .../app/controllers/widgets_controller.rb | 0 .../app/helpers/application_helper.rb | 0 .../test_app}/app/mailers/.gitkeep | 0 .../test_app}/app/models/.gitkeep | 0 .../test_app}/app/models/article.rb | 0 .../test_app}/app/models/dummy.rb | 0 .../test_app}/app/models/post.rb | 0 .../test_app}/app/models/user.rb | 0 .../test_app}/app/models/widget.rb | 0 .../app/views/articles/index.html.erb | 0 .../app/views/articles/show.html.erb | 0 .../test_app}/app/views/dummy/index.html.erb | 0 .../app/views/layouts/application.html.erb | 0 .../test_app}/app/views/posts/edit.html.erb | 0 .../test_app}/app/views/posts/index.html.erb | 0 .../test_app}/app/views/posts/show.html.erb | 0 .../app/views/widgets/index.html.erb | 0 .../test_app}/app/views/widgets/new.html.erb | 0 .../test_app}/app/views/widgets/show.html.erb | 0 {test_app => tests/test_app}/config.ru | 0 .../test_app}/config/application.rb | 0 {test_app => tests/test_app}/config/boot.rb | 0 .../test_app}/config/cucumber.yml | 0 .../test_app}/config/database.yml | 0 .../test_app}/config/environment.rb | 0 .../config/environments/development.rb | 0 .../test_app}/config/environments/pg_test.rb | 0 .../config/environments/production.rb | 0 .../test_app}/config/environments/test.rb | 0 .../initializers/backtrace_silencers.rb | 0 .../config/initializers/impression.rb | 0 .../config/initializers/inflections.rb | 0 .../config/initializers/mime_types.rb | 0 .../config/initializers/secret_token.rb | 0 .../config/initializers/session_store.rb | 0 .../config/initializers/wrap_parameters.rb | 0 .../test_app}/config/locales/en.yml | 0 {test_app => tests/test_app}/config/routes.rb | 0 .../migrate/20110201153144_create_articles.rb | 0 .../db/migrate/20110210205028_create_posts.rb | 0 .../migrate/20111127184039_create_widgets.rb | 0 tests/test_app/db/schema.rb | 60 ++++++++++++++++++ {test_app => tests/test_app}/db/seeds.rb | 0 .../test_app}/lib/assets/.gitkeep | 0 .../test_app}/lib/tasks/.gitkeep | 0 .../test_app}/lib/tasks/cucumber.rake | 0 {test_app => tests/test_app}/log/.gitkeep | 0 {test_app => tests/test_app}/public/404.html | 0 {test_app => tests/test_app}/public/422.html | 0 {test_app => tests/test_app}/public/500.html | 0 .../test_app}/public/favicon.ico | 0 .../test_app}/public/images/rails.png | Bin .../test_app}/public/index.html | 0 .../public/javascripts/application.js | 0 .../test_app}/public/javascripts/controls.js | 0 .../test_app}/public/javascripts/dragdrop.js | 0 .../test_app}/public/javascripts/effects.js | 0 .../test_app}/public/javascripts/prototype.js | 0 .../test_app}/public/javascripts/rails.js | 0 .../test_app}/public/robots.txt | 0 .../test_app}/public/stylesheets/.gitkeep | 0 {test_app => tests/test_app}/script/cucumber | 0 {test_app => tests/test_app}/script/rails | 0 .../controllers/articles_controller_spec.rb | 0 .../spec/controllers/dummy_controller_spec.rb | 0 .../impressionist_uniqueness_spec.rb | 0 .../spec/controllers/posts_controller_spec.rb | 0 .../controllers/widgets_controller_spec.rb | 0 .../test_app}/spec/fixtures/articles.yml | 0 .../test_app}/spec/fixtures/impressions.yml | 0 .../test_app}/spec/fixtures/posts.yml | 0 .../test_app}/spec/fixtures/widgets.yml | 0 .../spec/initializers/initializers_spec.rb | 0 .../test_app}/spec/models/bots_spec.rb | 0 .../spec/models/counter_caching_spec.rb | 0 .../test_app}/spec/models/model_spec.rb | 0 .../rails_generators/rails_generators_spec.rb | 0 .../test_app}/spec/spec_helper.rb | 0 95 files changed, 68 insertions(+), 10 deletions(-) delete mode 100644 spec/spec_helper.rb create mode 100644 tests/README rename {test_app => tests/test_app}/.gitignore (100%) rename {test_app => tests/test_app}/.rspec (100%) rename {test_app => tests/test_app}/Gemfile (100%) rename {test_app => tests/test_app}/README (100%) rename {test_app => tests/test_app}/README.rdoc (100%) rename {test_app => tests/test_app}/Rakefile (100%) rename {test_app => tests/test_app}/app/assets/images/rails.png (100%) rename {test_app => tests/test_app}/app/assets/javascripts/application.js (100%) rename {test_app => tests/test_app}/app/assets/stylesheets/application.css (100%) rename {test_app => tests/test_app}/app/controllers/application_controller.rb (100%) rename {test_app => tests/test_app}/app/controllers/articles_controller.rb (100%) rename {test_app => tests/test_app}/app/controllers/dummy_controller.rb (100%) rename {test_app => tests/test_app}/app/controllers/posts_controller.rb (100%) rename {test_app => tests/test_app}/app/controllers/widgets_controller.rb (100%) rename {test_app => tests/test_app}/app/helpers/application_helper.rb (100%) rename {test_app => tests/test_app}/app/mailers/.gitkeep (100%) rename {test_app => tests/test_app}/app/models/.gitkeep (100%) rename {test_app => tests/test_app}/app/models/article.rb (100%) rename {test_app => tests/test_app}/app/models/dummy.rb (100%) rename {test_app => tests/test_app}/app/models/post.rb (100%) rename {test_app => tests/test_app}/app/models/user.rb (100%) rename {test_app => tests/test_app}/app/models/widget.rb (100%) rename {test_app => tests/test_app}/app/views/articles/index.html.erb (100%) rename {test_app => tests/test_app}/app/views/articles/show.html.erb (100%) rename {test_app => tests/test_app}/app/views/dummy/index.html.erb (100%) rename {test_app => tests/test_app}/app/views/layouts/application.html.erb (100%) rename {test_app => tests/test_app}/app/views/posts/edit.html.erb (100%) rename {test_app => tests/test_app}/app/views/posts/index.html.erb (100%) rename {test_app => tests/test_app}/app/views/posts/show.html.erb (100%) rename {test_app => tests/test_app}/app/views/widgets/index.html.erb (100%) rename {test_app => tests/test_app}/app/views/widgets/new.html.erb (100%) rename {test_app => tests/test_app}/app/views/widgets/show.html.erb (100%) rename {test_app => tests/test_app}/config.ru (100%) rename {test_app => tests/test_app}/config/application.rb (100%) rename {test_app => tests/test_app}/config/boot.rb (100%) rename {test_app => tests/test_app}/config/cucumber.yml (100%) rename {test_app => tests/test_app}/config/database.yml (100%) rename {test_app => tests/test_app}/config/environment.rb (100%) rename {test_app => tests/test_app}/config/environments/development.rb (100%) rename {test_app => tests/test_app}/config/environments/pg_test.rb (100%) rename {test_app => tests/test_app}/config/environments/production.rb (100%) rename {test_app => tests/test_app}/config/environments/test.rb (100%) rename {test_app => tests/test_app}/config/initializers/backtrace_silencers.rb (100%) rename {test_app => tests/test_app}/config/initializers/impression.rb (100%) rename {test_app => tests/test_app}/config/initializers/inflections.rb (100%) rename {test_app => tests/test_app}/config/initializers/mime_types.rb (100%) rename {test_app => tests/test_app}/config/initializers/secret_token.rb (100%) rename {test_app => tests/test_app}/config/initializers/session_store.rb (100%) rename {test_app => tests/test_app}/config/initializers/wrap_parameters.rb (100%) rename {test_app => tests/test_app}/config/locales/en.yml (100%) rename {test_app => tests/test_app}/config/routes.rb (100%) rename {test_app => tests/test_app}/db/migrate/20110201153144_create_articles.rb (100%) rename {test_app => tests/test_app}/db/migrate/20110210205028_create_posts.rb (100%) rename {test_app => tests/test_app}/db/migrate/20111127184039_create_widgets.rb (100%) create mode 100644 tests/test_app/db/schema.rb rename {test_app => tests/test_app}/db/seeds.rb (100%) rename {test_app => tests/test_app}/lib/assets/.gitkeep (100%) rename {test_app => tests/test_app}/lib/tasks/.gitkeep (100%) rename {test_app => tests/test_app}/lib/tasks/cucumber.rake (100%) rename {test_app => tests/test_app}/log/.gitkeep (100%) rename {test_app => tests/test_app}/public/404.html (100%) rename {test_app => tests/test_app}/public/422.html (100%) rename {test_app => tests/test_app}/public/500.html (100%) rename {test_app => tests/test_app}/public/favicon.ico (100%) rename {test_app => tests/test_app}/public/images/rails.png (100%) rename {test_app => tests/test_app}/public/index.html (100%) rename {test_app => tests/test_app}/public/javascripts/application.js (100%) rename {test_app => tests/test_app}/public/javascripts/controls.js (100%) rename {test_app => tests/test_app}/public/javascripts/dragdrop.js (100%) rename {test_app => tests/test_app}/public/javascripts/effects.js (100%) rename {test_app => tests/test_app}/public/javascripts/prototype.js (100%) rename {test_app => tests/test_app}/public/javascripts/rails.js (100%) rename {test_app => tests/test_app}/public/robots.txt (100%) rename {test_app => tests/test_app}/public/stylesheets/.gitkeep (100%) rename {test_app => tests/test_app}/script/cucumber (100%) rename {test_app => tests/test_app}/script/rails (100%) rename {test_app => tests/test_app}/spec/controllers/articles_controller_spec.rb (100%) rename {test_app => tests/test_app}/spec/controllers/dummy_controller_spec.rb (100%) rename {test_app => tests/test_app}/spec/controllers/impressionist_uniqueness_spec.rb (100%) rename {test_app => tests/test_app}/spec/controllers/posts_controller_spec.rb (100%) rename {test_app => tests/test_app}/spec/controllers/widgets_controller_spec.rb (100%) rename {test_app => tests/test_app}/spec/fixtures/articles.yml (100%) rename {test_app => tests/test_app}/spec/fixtures/impressions.yml (100%) rename {test_app => tests/test_app}/spec/fixtures/posts.yml (100%) rename {test_app => tests/test_app}/spec/fixtures/widgets.yml (100%) rename {test_app => tests/test_app}/spec/initializers/initializers_spec.rb (100%) rename {test_app => tests/test_app}/spec/models/bots_spec.rb (100%) rename {test_app => tests/test_app}/spec/models/counter_caching_spec.rb (100%) rename {test_app => tests/test_app}/spec/models/model_spec.rb (100%) rename {test_app => tests/test_app}/spec/rails_generators/rails_generators_spec.rb (100%) rename {test_app => tests/test_app}/spec/spec_helper.rb (100%) diff --git a/Rakefile b/Rakefile index d808f16..37960c8 100644 --- a/Rakefile +++ b/Rakefile @@ -3,9 +3,10 @@ require 'rspec/core/rake_task' Bundler::GemHelper.install_tasks +# Impressionist will use MiniTest instead of RSpec RSpec::Core::RakeTask.new do |task| - task.rspec_opts = "-I ./test_app/spec" - task.pattern = "./test_app/spec/**/*_spec.rb" + task.rspec_opts = "-I ./tests/test_app/spec" + task.pattern = "./tests/test_app/spec/**/*_spec.rb" end task :test => :spec diff --git a/impressionist.gemspec b/impressionist.gemspec index 2b45fc2..85b78d3 100644 --- a/impressionist.gemspec +++ b/impressionist.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |s| s.authors = ['johnmcaliley'] s.files = `git ls-files`.split("\n") - s.test_files = `git ls-files -- {spec,test_app/spec}/*`.split("\n") + s.test_files = `git ls-files -- tests/**/*`.split("\n") s.require_path = 'lib' s.required_rubygems_version = Gem::Requirement.new('>= 1.3.6') if s.respond_to? :required_rubygems_version= @@ -26,11 +26,12 @@ Gem::Specification.new do |s| # Capybara has dropped support for Ruby 1.8.7 onwards version 2.0.3 s.add_development_dependency 'capybara', '>= 2.0.3' s.add_development_dependency 'rake', '>= 0.9' - s.add_development_dependency 'rails', '~> 3.1' + s.add_development_dependency 'rails', '>= 3.1' s.add_development_dependency 'rdoc', '>= 2.4.2' s.add_development_dependency 'rspec-rails' s.add_development_dependency 'simplecov' s.add_development_dependency 'sqlite3' s.add_development_dependency 'systemu' - + s.add_development_dependency 'minitest' + s.add_development_dependency 'minitest-rails' end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb deleted file mode 100644 index 92787cc..0000000 --- a/spec/spec_helper.rb +++ /dev/null @@ -1,5 +0,0 @@ -module Impressionist - def self.mattr_accessor(accessor) - class_variable_set("@@#{accessor}", accessor) - end -end diff --git a/tests/README b/tests/README new file mode 100644 index 0000000..6e3fe68 --- /dev/null +++ b/tests/README @@ -0,0 +1 @@ +Impressionist uses MiniTest diff --git a/test_app/.gitignore b/tests/test_app/.gitignore similarity index 100% rename from test_app/.gitignore rename to tests/test_app/.gitignore diff --git a/test_app/.rspec b/tests/test_app/.rspec similarity index 100% rename from test_app/.rspec rename to tests/test_app/.rspec diff --git a/test_app/Gemfile b/tests/test_app/Gemfile similarity index 100% rename from test_app/Gemfile rename to tests/test_app/Gemfile diff --git a/test_app/README b/tests/test_app/README similarity index 100% rename from test_app/README rename to tests/test_app/README diff --git a/test_app/README.rdoc b/tests/test_app/README.rdoc similarity index 100% rename from test_app/README.rdoc rename to tests/test_app/README.rdoc diff --git a/test_app/Rakefile b/tests/test_app/Rakefile similarity index 100% rename from test_app/Rakefile rename to tests/test_app/Rakefile diff --git a/test_app/app/assets/images/rails.png b/tests/test_app/app/assets/images/rails.png similarity index 100% rename from test_app/app/assets/images/rails.png rename to tests/test_app/app/assets/images/rails.png diff --git a/test_app/app/assets/javascripts/application.js b/tests/test_app/app/assets/javascripts/application.js similarity index 100% rename from test_app/app/assets/javascripts/application.js rename to tests/test_app/app/assets/javascripts/application.js diff --git a/test_app/app/assets/stylesheets/application.css b/tests/test_app/app/assets/stylesheets/application.css similarity index 100% rename from test_app/app/assets/stylesheets/application.css rename to tests/test_app/app/assets/stylesheets/application.css diff --git a/test_app/app/controllers/application_controller.rb b/tests/test_app/app/controllers/application_controller.rb similarity index 100% rename from test_app/app/controllers/application_controller.rb rename to tests/test_app/app/controllers/application_controller.rb diff --git a/test_app/app/controllers/articles_controller.rb b/tests/test_app/app/controllers/articles_controller.rb similarity index 100% rename from test_app/app/controllers/articles_controller.rb rename to tests/test_app/app/controllers/articles_controller.rb diff --git a/test_app/app/controllers/dummy_controller.rb b/tests/test_app/app/controllers/dummy_controller.rb similarity index 100% rename from test_app/app/controllers/dummy_controller.rb rename to tests/test_app/app/controllers/dummy_controller.rb diff --git a/test_app/app/controllers/posts_controller.rb b/tests/test_app/app/controllers/posts_controller.rb similarity index 100% rename from test_app/app/controllers/posts_controller.rb rename to tests/test_app/app/controllers/posts_controller.rb diff --git a/test_app/app/controllers/widgets_controller.rb b/tests/test_app/app/controllers/widgets_controller.rb similarity index 100% rename from test_app/app/controllers/widgets_controller.rb rename to tests/test_app/app/controllers/widgets_controller.rb diff --git a/test_app/app/helpers/application_helper.rb b/tests/test_app/app/helpers/application_helper.rb similarity index 100% rename from test_app/app/helpers/application_helper.rb rename to tests/test_app/app/helpers/application_helper.rb diff --git a/test_app/app/mailers/.gitkeep b/tests/test_app/app/mailers/.gitkeep similarity index 100% rename from test_app/app/mailers/.gitkeep rename to tests/test_app/app/mailers/.gitkeep diff --git a/test_app/app/models/.gitkeep b/tests/test_app/app/models/.gitkeep similarity index 100% rename from test_app/app/models/.gitkeep rename to tests/test_app/app/models/.gitkeep diff --git a/test_app/app/models/article.rb b/tests/test_app/app/models/article.rb similarity index 100% rename from test_app/app/models/article.rb rename to tests/test_app/app/models/article.rb diff --git a/test_app/app/models/dummy.rb b/tests/test_app/app/models/dummy.rb similarity index 100% rename from test_app/app/models/dummy.rb rename to tests/test_app/app/models/dummy.rb diff --git a/test_app/app/models/post.rb b/tests/test_app/app/models/post.rb similarity index 100% rename from test_app/app/models/post.rb rename to tests/test_app/app/models/post.rb diff --git a/test_app/app/models/user.rb b/tests/test_app/app/models/user.rb similarity index 100% rename from test_app/app/models/user.rb rename to tests/test_app/app/models/user.rb diff --git a/test_app/app/models/widget.rb b/tests/test_app/app/models/widget.rb similarity index 100% rename from test_app/app/models/widget.rb rename to tests/test_app/app/models/widget.rb diff --git a/test_app/app/views/articles/index.html.erb b/tests/test_app/app/views/articles/index.html.erb similarity index 100% rename from test_app/app/views/articles/index.html.erb rename to tests/test_app/app/views/articles/index.html.erb diff --git a/test_app/app/views/articles/show.html.erb b/tests/test_app/app/views/articles/show.html.erb similarity index 100% rename from test_app/app/views/articles/show.html.erb rename to tests/test_app/app/views/articles/show.html.erb diff --git a/test_app/app/views/dummy/index.html.erb b/tests/test_app/app/views/dummy/index.html.erb similarity index 100% rename from test_app/app/views/dummy/index.html.erb rename to tests/test_app/app/views/dummy/index.html.erb diff --git a/test_app/app/views/layouts/application.html.erb b/tests/test_app/app/views/layouts/application.html.erb similarity index 100% rename from test_app/app/views/layouts/application.html.erb rename to tests/test_app/app/views/layouts/application.html.erb diff --git a/test_app/app/views/posts/edit.html.erb b/tests/test_app/app/views/posts/edit.html.erb similarity index 100% rename from test_app/app/views/posts/edit.html.erb rename to tests/test_app/app/views/posts/edit.html.erb diff --git a/test_app/app/views/posts/index.html.erb b/tests/test_app/app/views/posts/index.html.erb similarity index 100% rename from test_app/app/views/posts/index.html.erb rename to tests/test_app/app/views/posts/index.html.erb diff --git a/test_app/app/views/posts/show.html.erb b/tests/test_app/app/views/posts/show.html.erb similarity index 100% rename from test_app/app/views/posts/show.html.erb rename to tests/test_app/app/views/posts/show.html.erb diff --git a/test_app/app/views/widgets/index.html.erb b/tests/test_app/app/views/widgets/index.html.erb similarity index 100% rename from test_app/app/views/widgets/index.html.erb rename to tests/test_app/app/views/widgets/index.html.erb diff --git a/test_app/app/views/widgets/new.html.erb b/tests/test_app/app/views/widgets/new.html.erb similarity index 100% rename from test_app/app/views/widgets/new.html.erb rename to tests/test_app/app/views/widgets/new.html.erb diff --git a/test_app/app/views/widgets/show.html.erb b/tests/test_app/app/views/widgets/show.html.erb similarity index 100% rename from test_app/app/views/widgets/show.html.erb rename to tests/test_app/app/views/widgets/show.html.erb diff --git a/test_app/config.ru b/tests/test_app/config.ru similarity index 100% rename from test_app/config.ru rename to tests/test_app/config.ru diff --git a/test_app/config/application.rb b/tests/test_app/config/application.rb similarity index 100% rename from test_app/config/application.rb rename to tests/test_app/config/application.rb diff --git a/test_app/config/boot.rb b/tests/test_app/config/boot.rb similarity index 100% rename from test_app/config/boot.rb rename to tests/test_app/config/boot.rb diff --git a/test_app/config/cucumber.yml b/tests/test_app/config/cucumber.yml similarity index 100% rename from test_app/config/cucumber.yml rename to tests/test_app/config/cucumber.yml diff --git a/test_app/config/database.yml b/tests/test_app/config/database.yml similarity index 100% rename from test_app/config/database.yml rename to tests/test_app/config/database.yml diff --git a/test_app/config/environment.rb b/tests/test_app/config/environment.rb similarity index 100% rename from test_app/config/environment.rb rename to tests/test_app/config/environment.rb diff --git a/test_app/config/environments/development.rb b/tests/test_app/config/environments/development.rb similarity index 100% rename from test_app/config/environments/development.rb rename to tests/test_app/config/environments/development.rb diff --git a/test_app/config/environments/pg_test.rb b/tests/test_app/config/environments/pg_test.rb similarity index 100% rename from test_app/config/environments/pg_test.rb rename to tests/test_app/config/environments/pg_test.rb diff --git a/test_app/config/environments/production.rb b/tests/test_app/config/environments/production.rb similarity index 100% rename from test_app/config/environments/production.rb rename to tests/test_app/config/environments/production.rb diff --git a/test_app/config/environments/test.rb b/tests/test_app/config/environments/test.rb similarity index 100% rename from test_app/config/environments/test.rb rename to tests/test_app/config/environments/test.rb diff --git a/test_app/config/initializers/backtrace_silencers.rb b/tests/test_app/config/initializers/backtrace_silencers.rb similarity index 100% rename from test_app/config/initializers/backtrace_silencers.rb rename to tests/test_app/config/initializers/backtrace_silencers.rb diff --git a/test_app/config/initializers/impression.rb b/tests/test_app/config/initializers/impression.rb similarity index 100% rename from test_app/config/initializers/impression.rb rename to tests/test_app/config/initializers/impression.rb diff --git a/test_app/config/initializers/inflections.rb b/tests/test_app/config/initializers/inflections.rb similarity index 100% rename from test_app/config/initializers/inflections.rb rename to tests/test_app/config/initializers/inflections.rb diff --git a/test_app/config/initializers/mime_types.rb b/tests/test_app/config/initializers/mime_types.rb similarity index 100% rename from test_app/config/initializers/mime_types.rb rename to tests/test_app/config/initializers/mime_types.rb diff --git a/test_app/config/initializers/secret_token.rb b/tests/test_app/config/initializers/secret_token.rb similarity index 100% rename from test_app/config/initializers/secret_token.rb rename to tests/test_app/config/initializers/secret_token.rb diff --git a/test_app/config/initializers/session_store.rb b/tests/test_app/config/initializers/session_store.rb similarity index 100% rename from test_app/config/initializers/session_store.rb rename to tests/test_app/config/initializers/session_store.rb diff --git a/test_app/config/initializers/wrap_parameters.rb b/tests/test_app/config/initializers/wrap_parameters.rb similarity index 100% rename from test_app/config/initializers/wrap_parameters.rb rename to tests/test_app/config/initializers/wrap_parameters.rb diff --git a/test_app/config/locales/en.yml b/tests/test_app/config/locales/en.yml similarity index 100% rename from test_app/config/locales/en.yml rename to tests/test_app/config/locales/en.yml diff --git a/test_app/config/routes.rb b/tests/test_app/config/routes.rb similarity index 100% rename from test_app/config/routes.rb rename to tests/test_app/config/routes.rb diff --git a/test_app/db/migrate/20110201153144_create_articles.rb b/tests/test_app/db/migrate/20110201153144_create_articles.rb similarity index 100% rename from test_app/db/migrate/20110201153144_create_articles.rb rename to tests/test_app/db/migrate/20110201153144_create_articles.rb diff --git a/test_app/db/migrate/20110210205028_create_posts.rb b/tests/test_app/db/migrate/20110210205028_create_posts.rb similarity index 100% rename from test_app/db/migrate/20110210205028_create_posts.rb rename to tests/test_app/db/migrate/20110210205028_create_posts.rb diff --git a/test_app/db/migrate/20111127184039_create_widgets.rb b/tests/test_app/db/migrate/20111127184039_create_widgets.rb similarity index 100% rename from test_app/db/migrate/20111127184039_create_widgets.rb rename to tests/test_app/db/migrate/20111127184039_create_widgets.rb diff --git a/tests/test_app/db/schema.rb b/tests/test_app/db/schema.rb new file mode 100644 index 0000000..b12fa39 --- /dev/null +++ b/tests/test_app/db/schema.rb @@ -0,0 +1,60 @@ +# encoding: UTF-8 +# This file is auto-generated from the current state of the database. Instead +# of editing this file, please use the migrations feature of Active Record to +# incrementally modify your database, and then regenerate this schema definition. +# +# Note that this schema.rb definition is the authoritative source for your +# database schema. If you need to create the application database on another +# system, you should be using db:schema:load, not running all the migrations +# from scratch. The latter is a flawed and unsustainable approach (the more migrations +# you'll amass, the slower it'll run and the greater likelihood for issues). +# +# It's strongly recommended to check this file into your version control system. + +ActiveRecord::Schema.define(:version => 20130709003307) do + + create_table "articles", :force => true do |t| + t.string "name" + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + end + + create_table "impressions", :force => true do |t| + t.string "impressionable_type" + t.integer "impressionable_id" + t.integer "user_id" + t.string "controller_name" + t.string "action_name" + t.string "view_name" + t.string "request_hash" + t.string "ip_address" + t.string "session_hash" + t.text "message" + t.text "referrer" + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + end + + add_index "impressions", ["controller_name", "action_name", "ip_address"], :name => "controlleraction_ip_index" + add_index "impressions", ["controller_name", "action_name", "request_hash"], :name => "controlleraction_request_index" + add_index "impressions", ["controller_name", "action_name", "session_hash"], :name => "controlleraction_session_index" + add_index "impressions", ["impressionable_type", "impressionable_id", "ip_address"], :name => "poly_ip_index" + add_index "impressions", ["impressionable_type", "impressionable_id", "request_hash"], :name => "poly_request_index" + add_index "impressions", ["impressionable_type", "impressionable_id", "session_hash"], :name => "poly_session_index" + add_index "impressions", ["impressionable_type", "message", "impressionable_id"], :name => "impressionable_type_message_index" + add_index "impressions", ["user_id"], :name => "index_impressions_on_user_id" + + create_table "posts", :force => true do |t| + t.string "name" + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + end + + create_table "widgets", :force => true do |t| + t.string "name" + t.integer "impressions_count", :default => 0 + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + end + +end diff --git a/test_app/db/seeds.rb b/tests/test_app/db/seeds.rb similarity index 100% rename from test_app/db/seeds.rb rename to tests/test_app/db/seeds.rb diff --git a/test_app/lib/assets/.gitkeep b/tests/test_app/lib/assets/.gitkeep similarity index 100% rename from test_app/lib/assets/.gitkeep rename to tests/test_app/lib/assets/.gitkeep diff --git a/test_app/lib/tasks/.gitkeep b/tests/test_app/lib/tasks/.gitkeep similarity index 100% rename from test_app/lib/tasks/.gitkeep rename to tests/test_app/lib/tasks/.gitkeep diff --git a/test_app/lib/tasks/cucumber.rake b/tests/test_app/lib/tasks/cucumber.rake similarity index 100% rename from test_app/lib/tasks/cucumber.rake rename to tests/test_app/lib/tasks/cucumber.rake diff --git a/test_app/log/.gitkeep b/tests/test_app/log/.gitkeep similarity index 100% rename from test_app/log/.gitkeep rename to tests/test_app/log/.gitkeep diff --git a/test_app/public/404.html b/tests/test_app/public/404.html similarity index 100% rename from test_app/public/404.html rename to tests/test_app/public/404.html diff --git a/test_app/public/422.html b/tests/test_app/public/422.html similarity index 100% rename from test_app/public/422.html rename to tests/test_app/public/422.html diff --git a/test_app/public/500.html b/tests/test_app/public/500.html similarity index 100% rename from test_app/public/500.html rename to tests/test_app/public/500.html diff --git a/test_app/public/favicon.ico b/tests/test_app/public/favicon.ico similarity index 100% rename from test_app/public/favicon.ico rename to tests/test_app/public/favicon.ico diff --git a/test_app/public/images/rails.png b/tests/test_app/public/images/rails.png similarity index 100% rename from test_app/public/images/rails.png rename to tests/test_app/public/images/rails.png diff --git a/test_app/public/index.html b/tests/test_app/public/index.html similarity index 100% rename from test_app/public/index.html rename to tests/test_app/public/index.html diff --git a/test_app/public/javascripts/application.js b/tests/test_app/public/javascripts/application.js similarity index 100% rename from test_app/public/javascripts/application.js rename to tests/test_app/public/javascripts/application.js diff --git a/test_app/public/javascripts/controls.js b/tests/test_app/public/javascripts/controls.js similarity index 100% rename from test_app/public/javascripts/controls.js rename to tests/test_app/public/javascripts/controls.js diff --git a/test_app/public/javascripts/dragdrop.js b/tests/test_app/public/javascripts/dragdrop.js similarity index 100% rename from test_app/public/javascripts/dragdrop.js rename to tests/test_app/public/javascripts/dragdrop.js diff --git a/test_app/public/javascripts/effects.js b/tests/test_app/public/javascripts/effects.js similarity index 100% rename from test_app/public/javascripts/effects.js rename to tests/test_app/public/javascripts/effects.js diff --git a/test_app/public/javascripts/prototype.js b/tests/test_app/public/javascripts/prototype.js similarity index 100% rename from test_app/public/javascripts/prototype.js rename to tests/test_app/public/javascripts/prototype.js diff --git a/test_app/public/javascripts/rails.js b/tests/test_app/public/javascripts/rails.js similarity index 100% rename from test_app/public/javascripts/rails.js rename to tests/test_app/public/javascripts/rails.js diff --git a/test_app/public/robots.txt b/tests/test_app/public/robots.txt similarity index 100% rename from test_app/public/robots.txt rename to tests/test_app/public/robots.txt diff --git a/test_app/public/stylesheets/.gitkeep b/tests/test_app/public/stylesheets/.gitkeep similarity index 100% rename from test_app/public/stylesheets/.gitkeep rename to tests/test_app/public/stylesheets/.gitkeep diff --git a/test_app/script/cucumber b/tests/test_app/script/cucumber similarity index 100% rename from test_app/script/cucumber rename to tests/test_app/script/cucumber diff --git a/test_app/script/rails b/tests/test_app/script/rails similarity index 100% rename from test_app/script/rails rename to tests/test_app/script/rails diff --git a/test_app/spec/controllers/articles_controller_spec.rb b/tests/test_app/spec/controllers/articles_controller_spec.rb similarity index 100% rename from test_app/spec/controllers/articles_controller_spec.rb rename to tests/test_app/spec/controllers/articles_controller_spec.rb diff --git a/test_app/spec/controllers/dummy_controller_spec.rb b/tests/test_app/spec/controllers/dummy_controller_spec.rb similarity index 100% rename from test_app/spec/controllers/dummy_controller_spec.rb rename to tests/test_app/spec/controllers/dummy_controller_spec.rb diff --git a/test_app/spec/controllers/impressionist_uniqueness_spec.rb b/tests/test_app/spec/controllers/impressionist_uniqueness_spec.rb similarity index 100% rename from test_app/spec/controllers/impressionist_uniqueness_spec.rb rename to tests/test_app/spec/controllers/impressionist_uniqueness_spec.rb diff --git a/test_app/spec/controllers/posts_controller_spec.rb b/tests/test_app/spec/controllers/posts_controller_spec.rb similarity index 100% rename from test_app/spec/controllers/posts_controller_spec.rb rename to tests/test_app/spec/controllers/posts_controller_spec.rb diff --git a/test_app/spec/controllers/widgets_controller_spec.rb b/tests/test_app/spec/controllers/widgets_controller_spec.rb similarity index 100% rename from test_app/spec/controllers/widgets_controller_spec.rb rename to tests/test_app/spec/controllers/widgets_controller_spec.rb diff --git a/test_app/spec/fixtures/articles.yml b/tests/test_app/spec/fixtures/articles.yml similarity index 100% rename from test_app/spec/fixtures/articles.yml rename to tests/test_app/spec/fixtures/articles.yml diff --git a/test_app/spec/fixtures/impressions.yml b/tests/test_app/spec/fixtures/impressions.yml similarity index 100% rename from test_app/spec/fixtures/impressions.yml rename to tests/test_app/spec/fixtures/impressions.yml diff --git a/test_app/spec/fixtures/posts.yml b/tests/test_app/spec/fixtures/posts.yml similarity index 100% rename from test_app/spec/fixtures/posts.yml rename to tests/test_app/spec/fixtures/posts.yml diff --git a/test_app/spec/fixtures/widgets.yml b/tests/test_app/spec/fixtures/widgets.yml similarity index 100% rename from test_app/spec/fixtures/widgets.yml rename to tests/test_app/spec/fixtures/widgets.yml diff --git a/test_app/spec/initializers/initializers_spec.rb b/tests/test_app/spec/initializers/initializers_spec.rb similarity index 100% rename from test_app/spec/initializers/initializers_spec.rb rename to tests/test_app/spec/initializers/initializers_spec.rb diff --git a/test_app/spec/models/bots_spec.rb b/tests/test_app/spec/models/bots_spec.rb similarity index 100% rename from test_app/spec/models/bots_spec.rb rename to tests/test_app/spec/models/bots_spec.rb diff --git a/test_app/spec/models/counter_caching_spec.rb b/tests/test_app/spec/models/counter_caching_spec.rb similarity index 100% rename from test_app/spec/models/counter_caching_spec.rb rename to tests/test_app/spec/models/counter_caching_spec.rb diff --git a/test_app/spec/models/model_spec.rb b/tests/test_app/spec/models/model_spec.rb similarity index 100% rename from test_app/spec/models/model_spec.rb rename to tests/test_app/spec/models/model_spec.rb diff --git a/test_app/spec/rails_generators/rails_generators_spec.rb b/tests/test_app/spec/rails_generators/rails_generators_spec.rb similarity index 100% rename from test_app/spec/rails_generators/rails_generators_spec.rb rename to tests/test_app/spec/rails_generators/rails_generators_spec.rb diff --git a/test_app/spec/spec_helper.rb b/tests/test_app/spec/spec_helper.rb similarity index 100% rename from test_app/spec/spec_helper.rb rename to tests/test_app/spec/spec_helper.rb