sapience 1.0.11 → 1.0.12

Sign up to get free protection for your applications and to get access to all the features.
Files changed (121) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +5 -0
  3. data/lib/sapience/extensions/grape/middleware/logging.rb +4 -11
  4. data/lib/sapience/extensions/grape/notifications.rb +4 -1
  5. data/lib/sapience/extensions/grape/request_format_helper.rb +12 -0
  6. data/lib/sapience/version.rb +1 -1
  7. data/sapience.gemspec +1 -1
  8. metadata +3 -115
  9. data/test_apps/grape/.gitignore +0 -41
  10. data/test_apps/grape/.rspec +0 -1
  11. data/test_apps/grape/.simplecov +0 -25
  12. data/test_apps/grape/Appraisals +0 -9
  13. data/test_apps/grape/Gemfile +0 -31
  14. data/test_apps/grape/Rakefile +0 -8
  15. data/test_apps/grape/config.ru +0 -5
  16. data/test_apps/grape/gemfiles/grape_0.16.2.gemfile +0 -26
  17. data/test_apps/grape/gemfiles/grape_0.16.2.gemfile.lock +0 -140
  18. data/test_apps/grape/gemfiles/grape_0.17.0.gemfile +0 -25
  19. data/test_apps/grape/gemfiles/grape_0.17.0.gemfile.lock +0 -138
  20. data/test_apps/grape/lib/ping/api.rb +0 -21
  21. data/test_apps/grape/lib/ping.rb +0 -3
  22. data/test_apps/grape/spec/lib/ping/api_spec.rb +0 -81
  23. data/test_apps/grape/spec/spec_helper.rb +0 -26
  24. data/test_apps/rails/.gitignore +0 -37
  25. data/test_apps/rails/.rspec +0 -1
  26. data/test_apps/rails/.ruby-version +0 -1
  27. data/test_apps/rails/.simplecov +0 -25
  28. data/test_apps/rails/Gemfile +0 -48
  29. data/test_apps/rails/README.md +0 -24
  30. data/test_apps/rails/Rakefile +0 -12
  31. data/test_apps/rails/app/assets/config/manifest.js +0 -2
  32. data/test_apps/rails/app/assets/images/.keep +0 -0
  33. data/test_apps/rails/app/assets/javascripts/posts.js +0 -2
  34. data/test_apps/rails/app/assets/stylesheets/application.css +0 -15
  35. data/test_apps/rails/app/assets/stylesheets/posts.css +0 -4
  36. data/test_apps/rails/app/assets/stylesheets/scaffold.css +0 -84
  37. data/test_apps/rails/app/channels/application_cable/channel.rb +0 -4
  38. data/test_apps/rails/app/channels/application_cable/connection.rb +0 -4
  39. data/test_apps/rails/app/controllers/application_controller.rb +0 -3
  40. data/test_apps/rails/app/controllers/concerns/.keep +0 -0
  41. data/test_apps/rails/app/controllers/posts_controller.rb +0 -59
  42. data/test_apps/rails/app/helpers/application_helper.rb +0 -2
  43. data/test_apps/rails/app/helpers/posts_helper.rb +0 -2
  44. data/test_apps/rails/app/jobs/application_job.rb +0 -2
  45. data/test_apps/rails/app/jobs/test_job.rb +0 -12
  46. data/test_apps/rails/app/mailers/application_mailer.rb +0 -4
  47. data/test_apps/rails/app/models/application_record.rb +0 -3
  48. data/test_apps/rails/app/models/concerns/.keep +0 -0
  49. data/test_apps/rails/app/models/post.rb +0 -3
  50. data/test_apps/rails/app/models/user.rb +0 -3
  51. data/test_apps/rails/app/views/layouts/application.html.erb +0 -13
  52. data/test_apps/rails/app/views/layouts/mailer.html.erb +0 -13
  53. data/test_apps/rails/app/views/layouts/mailer.text.erb +0 -1
  54. data/test_apps/rails/app/views/posts/_form.html.slim +0 -18
  55. data/test_apps/rails/app/views/posts/edit.html.slim +0 -8
  56. data/test_apps/rails/app/views/posts/index.html.slim +0 -25
  57. data/test_apps/rails/app/views/posts/new.html.slim +0 -5
  58. data/test_apps/rails/app/views/posts/show.html.slim +0 -15
  59. data/test_apps/rails/app/workers/test_worker.rb +0 -17
  60. data/test_apps/rails/bin/bundle +0 -3
  61. data/test_apps/rails/bin/rails +0 -4
  62. data/test_apps/rails/bin/rake +0 -4
  63. data/test_apps/rails/bin/setup +0 -34
  64. data/test_apps/rails/bin/sneakers +0 -10
  65. data/test_apps/rails/bin/update +0 -29
  66. data/test_apps/rails/config/application.rb +0 -25
  67. data/test_apps/rails/config/boot.rb +0 -3
  68. data/test_apps/rails/config/cable.yml +0 -9
  69. data/test_apps/rails/config/database.yml +0 -24
  70. data/test_apps/rails/config/environment.rb +0 -5
  71. data/test_apps/rails/config/environments/development.rb +0 -49
  72. data/test_apps/rails/config/environments/production.rb +0 -78
  73. data/test_apps/rails/config/environments/test.rb +0 -42
  74. data/test_apps/rails/config/initializers/application_controller_renderer.rb +0 -6
  75. data/test_apps/rails/config/initializers/backtrace_silencers.rb +0 -7
  76. data/test_apps/rails/config/initializers/cookies_serializer.rb +0 -5
  77. data/test_apps/rails/config/initializers/filter_parameter_logging.rb +0 -4
  78. data/test_apps/rails/config/initializers/inflections.rb +0 -16
  79. data/test_apps/rails/config/initializers/mime_types.rb +0 -4
  80. data/test_apps/rails/config/initializers/new_framework_defaults.rb +0 -24
  81. data/test_apps/rails/config/initializers/session_store.rb +0 -3
  82. data/test_apps/rails/config/initializers/sneakers.rb +0 -14
  83. data/test_apps/rails/config/initializers/wrap_parameters.rb +0 -14
  84. data/test_apps/rails/config/locales/en.yml +0 -23
  85. data/test_apps/rails/config/puma.rb +0 -45
  86. data/test_apps/rails/config/routes.rb +0 -3
  87. data/test_apps/rails/config/sapience_example.yml +0 -24
  88. data/test_apps/rails/config/secrets.yml +0 -22
  89. data/test_apps/rails/config.ru +0 -5
  90. data/test_apps/rails/db/migrate/20160812092236_create_users.rb +0 -13
  91. data/test_apps/rails/db/migrate/20160902141445_create_posts.rb +0 -17
  92. data/test_apps/rails/db/schema.rb +0 -37
  93. data/test_apps/rails/db/seeds.rb +0 -7
  94. data/test_apps/rails/lib/assets/.keep +0 -0
  95. data/test_apps/rails/lib/external_sneaker.rb +0 -46
  96. data/test_apps/rails/lib/tasks/.keep +0 -0
  97. data/test_apps/rails/lib/tasks/sneakers.rake +0 -21
  98. data/test_apps/rails/public/404.html +0 -67
  99. data/test_apps/rails/public/422.html +0 -67
  100. data/test_apps/rails/public/500.html +0 -66
  101. data/test_apps/rails/public/apple-touch-icon-precomposed.png +0 -0
  102. data/test_apps/rails/public/apple-touch-icon.png +0 -0
  103. data/test_apps/rails/public/favicon.ico +0 -0
  104. data/test_apps/rails/public/robots.txt +0 -5
  105. data/test_apps/rails/spec/controllers/posts_controller_spec.rb +0 -7
  106. data/test_apps/rails/spec/factories/posts.rb +0 -7
  107. data/test_apps/rails/spec/factories/users.rb +0 -8
  108. data/test_apps/rails/spec/fixtures/sapience.yml +0 -15
  109. data/test_apps/rails/spec/integration/sapience_spec.rb +0 -14
  110. data/test_apps/rails/spec/jobs/test_job_spec.rb +0 -36
  111. data/test_apps/rails/spec/models/post_spec.rb +0 -14
  112. data/test_apps/rails/spec/rails_helper.rb +0 -45
  113. data/test_apps/rails/spec/requests/posts_spec.rb +0 -44
  114. data/test_apps/rails/spec/routing/posts_routing_spec.rb +0 -37
  115. data/test_apps/rails/spec/spec_helper.rb +0 -16
  116. data/test_apps/rails/spec/views/posts/edit.html.slim_spec.rb +0 -17
  117. data/test_apps/rails/spec/views/posts/index.html.slim_spec.rb +0 -17
  118. data/test_apps/rails/spec/views/posts/new.html.slim_spec.rb +0 -17
  119. data/test_apps/rails/spec/views/posts/show.html.slim_spec.rb +0 -14
  120. data/test_apps/rails/spec/workers/test_worker_spec.rb +0 -41
  121. data/test_apps/rails/vendor/assets/stylesheets/.keep +0 -0
@@ -1,16 +0,0 @@
1
- RSpec.configure do |config|
2
- config.expect_with :rspec do |expectations|
3
- expectations.include_chain_clauses_in_custom_matcher_descriptions = true
4
- end
5
-
6
- config.mock_with :rspec do |mocks|
7
- mocks.verify_partial_doubles = true
8
- end
9
-
10
- config.shared_context_metadata_behavior = :apply_to_host_groups
11
- config.filter_run_when_matching :focus
12
- config.example_status_persistence_file_path = "spec/examples.txt"
13
- config.default_formatter = "doc" if config.files_to_run.one?
14
- config.order = :random
15
- Kernel.srand config.seed
16
- end
@@ -1,17 +0,0 @@
1
- require "rails_helper"
2
-
3
- RSpec.describe "posts/edit", type: :view do
4
- let(:post) { create(:post, title: "Title", body: "Body") }
5
- before(:each) do
6
- @post = assign(:post, post)
7
- end
8
-
9
- it "renders the edit post form" do
10
- render
11
-
12
- assert_select "form[action=?][method=?]", post_path(@post), "post" do
13
- assert_select "input#post_title[name=?]", "post[title]"
14
- assert_select "input#post_body[name=?]", "post[body]"
15
- end
16
- end
17
- end
@@ -1,17 +0,0 @@
1
- require "rails_helper"
2
-
3
- RSpec.describe "posts/index", type: :view do
4
- let(:posts) { [create(:post, title: "Title", body: "Body"), create(:post)] }
5
- before(:each) do
6
- assign(:posts, posts)
7
- end
8
-
9
- it "renders a list of posts" do
10
- render
11
- assert_select "tr>td", text: "Title", count: 1
12
- assert_select "tr>td", text: "Body", count: 1
13
-
14
- assert_select "tr>td", text: "This is a post", count: 1
15
- assert_select "tr>td", text: "It has a lot of content", count: 1
16
- end
17
- end
@@ -1,17 +0,0 @@
1
- require "rails_helper"
2
-
3
- RSpec.describe "posts/new", type: :view do
4
- let(:post) { build :post }
5
- before(:each) do
6
- assign(:post, post)
7
- end
8
-
9
- it "renders new post form" do
10
- render
11
-
12
- assert_select "form[action=?][method=?]", posts_path, "post" do
13
- assert_select "input#post_title[name=?]", "post[title]"
14
- assert_select "input#post_body[name=?]", "post[body]"
15
- end
16
- end
17
- end
@@ -1,14 +0,0 @@
1
- require "rails_helper"
2
-
3
- RSpec.describe "posts/show", type: :view do
4
- let(:post) { create(:post, title: "Title", body: "Body") }
5
- before(:each) do
6
- @post = assign(:post, post)
7
- end
8
-
9
- it "renders attributes in <p>" do
10
- render
11
- expect(rendered).to match(/Title/)
12
- expect(rendered).to match(/Body/)
13
- end
14
- end
@@ -1,41 +0,0 @@
1
- require "rails_helper"
2
- require "serverengine"
3
- require "sneakers"
4
- require "sneakers/runner"
5
- require "external_sneaker"
6
-
7
- describe TestWorker, :skip do
8
- include FileHelper
9
- let(:message) do
10
- {
11
- title: "Cool",
12
- body: "Hot",
13
- }
14
- end
15
-
16
- before do
17
- @sneakers_worker = ExternalSneaker.new("rake sneakers:run", described_class)
18
- @sneakers_worker.start
19
- Sneakers.publish(
20
- message.to_json,
21
- to_queue: described_class::QUEUE_NAME,
22
- routing_key: described_class::ROUTING_KEY,
23
- )
24
- end
25
-
26
- after do
27
- delete_file("config/sapience.yml")
28
- delete_file(described_class::VERIFICATION_FILE)
29
- end
30
-
31
- # TODO: Possible make this less flaky or run it with retry (rspec-retry)
32
- it "runs properly" do
33
- count = 0
34
- until File.exist?(described_class::VERIFICATION_FILE)
35
- sleep 0.1
36
- count += 1
37
- expect(true).to be(false) if count > 240
38
- end
39
- expect(true).to be(true)
40
- end
41
- end
File without changes