appmap 0.38.1 → 0.41.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (106) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +5 -1
  3. data/.travis.yml +2 -23
  4. data/CHANGELOG.md +26 -1
  5. data/CONTRIBUTING.md +22 -0
  6. data/README.md +119 -53
  7. data/Rakefile +3 -3
  8. data/lib/appmap/class_map.rb +25 -8
  9. data/lib/appmap/config.rb +41 -21
  10. data/lib/appmap/event.rb +14 -4
  11. data/lib/appmap/hook.rb +18 -3
  12. data/lib/appmap/rails/request_handler.rb +17 -3
  13. data/lib/appmap/railtie.rb +1 -5
  14. data/lib/appmap/version.rb +2 -2
  15. data/spec/abstract_controller_base_spec.rb +116 -86
  16. data/spec/config_spec.rb +1 -0
  17. data/spec/fixtures/hook/exclude.rb +15 -0
  18. data/spec/fixtures/hook/labels.rb +6 -0
  19. data/spec/fixtures/rails5_users_app/Gemfile +2 -3
  20. data/spec/fixtures/rails5_users_app/app/controllers/users_controller.rb +8 -0
  21. data/spec/fixtures/rails5_users_app/appmap.yml +4 -1
  22. data/spec/fixtures/rails5_users_app/config/application.rb +2 -0
  23. data/spec/fixtures/rails5_users_app/config/routes.rb +1 -1
  24. data/spec/fixtures/rails5_users_app/spec/controllers/users_controller_spec.rb +11 -0
  25. data/spec/fixtures/rails6_users_app/Gemfile +2 -3
  26. data/spec/fixtures/rails6_users_app/app/controllers/users_controller.rb +8 -0
  27. data/spec/fixtures/rails6_users_app/appmap.yml +4 -1
  28. data/spec/fixtures/rails6_users_app/config/application.rb +2 -0
  29. data/spec/fixtures/rails6_users_app/config/routes.rb +1 -1
  30. data/spec/fixtures/rails6_users_app/spec/controllers/users_controller_spec.rb +11 -0
  31. data/spec/hook_spec.rb +41 -41
  32. data/spec/rails_spec_helper.rb +2 -2
  33. data/spec/record_sql_rails_pg_spec.rb +1 -1
  34. data/spec/rspec_feature_metadata_spec.rb +1 -1
  35. data/spec/spec_helper.rb +1 -0
  36. data/test/fixtures/gem_test/appmap.yml +1 -1
  37. data/test/fixtures/gem_test/test/parser_test.rb +12 -0
  38. data/test/gem_test.rb +4 -4
  39. metadata +6 -69
  40. data/spec/abstract_controller4_base_spec.rb +0 -66
  41. data/spec/fixtures/rails4_users_app/.gitignore +0 -13
  42. data/spec/fixtures/rails4_users_app/.rbenv-gemsets +0 -2
  43. data/spec/fixtures/rails4_users_app/.ruby-version +0 -1
  44. data/spec/fixtures/rails4_users_app/Dockerfile +0 -30
  45. data/spec/fixtures/rails4_users_app/Dockerfile.pg +0 -3
  46. data/spec/fixtures/rails4_users_app/Gemfile +0 -77
  47. data/spec/fixtures/rails4_users_app/README.rdoc +0 -28
  48. data/spec/fixtures/rails4_users_app/Rakefile +0 -6
  49. data/spec/fixtures/rails4_users_app/app/assets/images/.keep +0 -0
  50. data/spec/fixtures/rails4_users_app/app/assets/javascripts/application.js +0 -16
  51. data/spec/fixtures/rails4_users_app/app/assets/stylesheets/application.css +0 -15
  52. data/spec/fixtures/rails4_users_app/app/controllers/api/users_controller.rb +0 -27
  53. data/spec/fixtures/rails4_users_app/app/controllers/application_controller.rb +0 -5
  54. data/spec/fixtures/rails4_users_app/app/controllers/concerns/.keep +0 -0
  55. data/spec/fixtures/rails4_users_app/app/controllers/health_controller.rb +0 -5
  56. data/spec/fixtures/rails4_users_app/app/controllers/users_controller.rb +0 -5
  57. data/spec/fixtures/rails4_users_app/app/helpers/application_helper.rb +0 -2
  58. data/spec/fixtures/rails4_users_app/app/mailers/.keep +0 -0
  59. data/spec/fixtures/rails4_users_app/app/models/.keep +0 -0
  60. data/spec/fixtures/rails4_users_app/app/models/concerns/.keep +0 -0
  61. data/spec/fixtures/rails4_users_app/app/models/user.rb +0 -18
  62. data/spec/fixtures/rails4_users_app/app/views/layouts/application.html.haml +0 -7
  63. data/spec/fixtures/rails4_users_app/app/views/users/index.html.haml +0 -7
  64. data/spec/fixtures/rails4_users_app/appmap.yml +0 -3
  65. data/spec/fixtures/rails4_users_app/bin/rails +0 -9
  66. data/spec/fixtures/rails4_users_app/bin/setup +0 -29
  67. data/spec/fixtures/rails4_users_app/bin/spring +0 -17
  68. data/spec/fixtures/rails4_users_app/config.ru +0 -4
  69. data/spec/fixtures/rails4_users_app/config/application.rb +0 -26
  70. data/spec/fixtures/rails4_users_app/config/boot.rb +0 -3
  71. data/spec/fixtures/rails4_users_app/config/database.yml +0 -18
  72. data/spec/fixtures/rails4_users_app/config/environment.rb +0 -5
  73. data/spec/fixtures/rails4_users_app/config/environments/development.rb +0 -41
  74. data/spec/fixtures/rails4_users_app/config/environments/production.rb +0 -79
  75. data/spec/fixtures/rails4_users_app/config/environments/test.rb +0 -42
  76. data/spec/fixtures/rails4_users_app/config/initializers/assets.rb +0 -11
  77. data/spec/fixtures/rails4_users_app/config/initializers/backtrace_silencers.rb +0 -7
  78. data/spec/fixtures/rails4_users_app/config/initializers/cookies_serializer.rb +0 -3
  79. data/spec/fixtures/rails4_users_app/config/initializers/filter_parameter_logging.rb +0 -4
  80. data/spec/fixtures/rails4_users_app/config/initializers/inflections.rb +0 -16
  81. data/spec/fixtures/rails4_users_app/config/initializers/mime_types.rb +0 -4
  82. data/spec/fixtures/rails4_users_app/config/initializers/session_store.rb +0 -3
  83. data/spec/fixtures/rails4_users_app/config/initializers/to_time_preserves_timezone.rb +0 -10
  84. data/spec/fixtures/rails4_users_app/config/initializers/wrap_parameters.rb +0 -14
  85. data/spec/fixtures/rails4_users_app/config/locales/en.yml +0 -23
  86. data/spec/fixtures/rails4_users_app/config/routes.rb +0 -12
  87. data/spec/fixtures/rails4_users_app/config/secrets.yml +0 -22
  88. data/spec/fixtures/rails4_users_app/create_app +0 -23
  89. data/spec/fixtures/rails4_users_app/db/migrate/20191127112304_create_users.rb +0 -10
  90. data/spec/fixtures/rails4_users_app/db/schema.rb +0 -26
  91. data/spec/fixtures/rails4_users_app/db/seeds.rb +0 -7
  92. data/spec/fixtures/rails4_users_app/docker-compose.yml +0 -26
  93. data/spec/fixtures/rails4_users_app/lib/assets/.keep +0 -0
  94. data/spec/fixtures/rails4_users_app/lib/tasks/.keep +0 -0
  95. data/spec/fixtures/rails4_users_app/log/.keep +0 -0
  96. data/spec/fixtures/rails4_users_app/public/404.html +0 -67
  97. data/spec/fixtures/rails4_users_app/public/422.html +0 -67
  98. data/spec/fixtures/rails4_users_app/public/500.html +0 -66
  99. data/spec/fixtures/rails4_users_app/public/favicon.ico +0 -0
  100. data/spec/fixtures/rails4_users_app/public/robots.txt +0 -5
  101. data/spec/fixtures/rails4_users_app/spec/controllers/users_controller_api_spec.rb +0 -49
  102. data/spec/fixtures/rails4_users_app/spec/rails_helper.rb +0 -95
  103. data/spec/fixtures/rails4_users_app/spec/spec_helper.rb +0 -96
  104. data/spec/fixtures/rails4_users_app/test/fixtures/users.yml +0 -9
  105. data/spec/record_sql_rails4_pg_spec.rb +0 -75
  106. data/test/fixtures/gem_test/test/to_param_test.rb +0 -14
@@ -1,7 +0,0 @@
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)
@@ -1,26 +0,0 @@
1
- version: "3"
2
- services:
3
- pg:
4
- build:
5
- context: .
6
- dockerfile: Dockerfile.pg
7
- ports:
8
- - "5432"
9
- environment:
10
- POSTGRES_HOST_AUTH_METHOD: trust
11
-
12
- app:
13
- build:
14
- context: .
15
- dockerfile: Dockerfile
16
- image: rails4-app:${RUBY_VERSION}
17
- command:
18
- [ "./bin/rails", "server", "-b", "0.0.0.0", "webrick" ]
19
- environment:
20
- RAILS_ENV:
21
- volumes:
22
- - .:/src/app
23
- ports:
24
- - "3000"
25
- links:
26
- - pg:pg
File without changes
File without changes
File without changes
@@ -1,67 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>The page you were looking for doesn't exist (404)</title>
5
- <meta name="viewport" content="width=device-width,initial-scale=1">
6
- <style>
7
- body {
8
- background-color: #EFEFEF;
9
- color: #2E2F30;
10
- text-align: center;
11
- font-family: arial, sans-serif;
12
- margin: 0;
13
- }
14
-
15
- div.dialog {
16
- width: 95%;
17
- max-width: 33em;
18
- margin: 4em auto 0;
19
- }
20
-
21
- div.dialog > div {
22
- border: 1px solid #CCC;
23
- border-right-color: #999;
24
- border-left-color: #999;
25
- border-bottom-color: #BBB;
26
- border-top: #B00100 solid 4px;
27
- border-top-left-radius: 9px;
28
- border-top-right-radius: 9px;
29
- background-color: white;
30
- padding: 7px 12% 0;
31
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
32
- }
33
-
34
- h1 {
35
- font-size: 100%;
36
- color: #730E15;
37
- line-height: 1.5em;
38
- }
39
-
40
- div.dialog > p {
41
- margin: 0 0 1em;
42
- padding: 1em;
43
- background-color: #F7F7F7;
44
- border: 1px solid #CCC;
45
- border-right-color: #999;
46
- border-left-color: #999;
47
- border-bottom-color: #999;
48
- border-bottom-left-radius: 4px;
49
- border-bottom-right-radius: 4px;
50
- border-top-color: #DADADA;
51
- color: #666;
52
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
53
- }
54
- </style>
55
- </head>
56
-
57
- <body>
58
- <!-- This file lives in public/404.html -->
59
- <div class="dialog">
60
- <div>
61
- <h1>The page you were looking for doesn't exist.</h1>
62
- <p>You may have mistyped the address or the page may have moved.</p>
63
- </div>
64
- <p>If you are the application owner check the logs for more information.</p>
65
- </div>
66
- </body>
67
- </html>
@@ -1,67 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>The change you wanted was rejected (422)</title>
5
- <meta name="viewport" content="width=device-width,initial-scale=1">
6
- <style>
7
- body {
8
- background-color: #EFEFEF;
9
- color: #2E2F30;
10
- text-align: center;
11
- font-family: arial, sans-serif;
12
- margin: 0;
13
- }
14
-
15
- div.dialog {
16
- width: 95%;
17
- max-width: 33em;
18
- margin: 4em auto 0;
19
- }
20
-
21
- div.dialog > div {
22
- border: 1px solid #CCC;
23
- border-right-color: #999;
24
- border-left-color: #999;
25
- border-bottom-color: #BBB;
26
- border-top: #B00100 solid 4px;
27
- border-top-left-radius: 9px;
28
- border-top-right-radius: 9px;
29
- background-color: white;
30
- padding: 7px 12% 0;
31
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
32
- }
33
-
34
- h1 {
35
- font-size: 100%;
36
- color: #730E15;
37
- line-height: 1.5em;
38
- }
39
-
40
- div.dialog > p {
41
- margin: 0 0 1em;
42
- padding: 1em;
43
- background-color: #F7F7F7;
44
- border: 1px solid #CCC;
45
- border-right-color: #999;
46
- border-left-color: #999;
47
- border-bottom-color: #999;
48
- border-bottom-left-radius: 4px;
49
- border-bottom-right-radius: 4px;
50
- border-top-color: #DADADA;
51
- color: #666;
52
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
53
- }
54
- </style>
55
- </head>
56
-
57
- <body>
58
- <!-- This file lives in public/422.html -->
59
- <div class="dialog">
60
- <div>
61
- <h1>The change you wanted was rejected.</h1>
62
- <p>Maybe you tried to change something you didn't have access to.</p>
63
- </div>
64
- <p>If you are the application owner check the logs for more information.</p>
65
- </div>
66
- </body>
67
- </html>
@@ -1,66 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>We're sorry, but something went wrong (500)</title>
5
- <meta name="viewport" content="width=device-width,initial-scale=1">
6
- <style>
7
- body {
8
- background-color: #EFEFEF;
9
- color: #2E2F30;
10
- text-align: center;
11
- font-family: arial, sans-serif;
12
- margin: 0;
13
- }
14
-
15
- div.dialog {
16
- width: 95%;
17
- max-width: 33em;
18
- margin: 4em auto 0;
19
- }
20
-
21
- div.dialog > div {
22
- border: 1px solid #CCC;
23
- border-right-color: #999;
24
- border-left-color: #999;
25
- border-bottom-color: #BBB;
26
- border-top: #B00100 solid 4px;
27
- border-top-left-radius: 9px;
28
- border-top-right-radius: 9px;
29
- background-color: white;
30
- padding: 7px 12% 0;
31
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
32
- }
33
-
34
- h1 {
35
- font-size: 100%;
36
- color: #730E15;
37
- line-height: 1.5em;
38
- }
39
-
40
- div.dialog > p {
41
- margin: 0 0 1em;
42
- padding: 1em;
43
- background-color: #F7F7F7;
44
- border: 1px solid #CCC;
45
- border-right-color: #999;
46
- border-left-color: #999;
47
- border-bottom-color: #999;
48
- border-bottom-left-radius: 4px;
49
- border-bottom-right-radius: 4px;
50
- border-top-color: #DADADA;
51
- color: #666;
52
- box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
53
- }
54
- </style>
55
- </head>
56
-
57
- <body>
58
- <!-- This file lives in public/500.html -->
59
- <div class="dialog">
60
- <div>
61
- <h1>We're sorry, but something went wrong.</h1>
62
- </div>
63
- <p>If you are the application owner check the logs for more information.</p>
64
- </div>
65
- </body>
66
- </html>
File without changes
@@ -1,5 +0,0 @@
1
- # See http://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file
2
- #
3
- # To ban all spiders from the entire site uncomment the next two lines:
4
- # User-agent: *
5
- # Disallow: /
@@ -1,49 +0,0 @@
1
- require 'rails_helper'
2
- require 'rack/test'
3
-
4
- RSpec.describe Api::UsersController, feature_group: 'Users', type: :controller, appmap: true do
5
-
6
- describe 'POST /api/users', feature: 'Create a user' do
7
- describe 'with required parameters' do
8
- it 'creates a user' do
9
- post :create, { login: 'alice', password: 'foobar' }
10
- expect(response.status).to eq(201)
11
- end
12
- end
13
- describe 'with a missing parameter' do
14
- it 'reports error 422' do
15
- post :create, {}
16
- expect(response.status).to eq(422)
17
- end
18
- end
19
- end
20
- describe 'GET /api/users', feature: 'List users' do
21
- before do
22
- post :create, { login: 'alice', password: 'secret' }
23
- end
24
- it 'lists the users' do
25
- post :index, {}
26
- users = JSON.parse(response.body)
27
- expect(users.map { |r| r['login'] }).to include('alice')
28
- end
29
- end
30
-
31
- context 'when parameterizing a string' do
32
- context 'using the inflector' do
33
- it 'uses the default separator' do
34
- expect(ActiveSupport::Inflector.parameterize('foo bar baz')).to eq('foo-bar-baz')
35
- end
36
- it 'uses a specified separator' do
37
- expect(ActiveSupport::Inflector.parameterize('foo bar baz', '+')).to eq('foo+bar+baz')
38
- end
39
- end
40
- context 'with #parameterize' do
41
- it 'uses the default separator' do
42
- expect('foo bar baz'.parameterize).to eq('foo-bar-baz')
43
- end
44
- it 'uses a specified separator' do
45
- expect('foo bar baz'.parameterize('+')).to eq('foo+bar+baz')
46
- end
47
- end
48
- end
49
- end
@@ -1,95 +0,0 @@
1
- STDERR.puts "rails4_users_app rails_helper"
2
- # This file is copied to spec/ when you run 'rails generate rspec:install'
3
- require 'spec_helper'
4
- ENV['RAILS_ENV'] ||= 'test'
5
-
6
- require File.expand_path('../config/environment', __dir__)
7
-
8
- # Prevent database truncation if the environment is production
9
- abort("The Rails environment is running in production mode!") if Rails.env.production?
10
- require 'rspec/rails'
11
- # Add additional requires below this line. Rails is not loaded until this point!
12
-
13
- # The issue this hack works around is discussed here
14
- # https://github.com/rails/rails/issues/34790, with the comment that
15
- # it won't be fixed here:
16
- # https://github.com/rails/rails/issues/34790#issuecomment-450036849
17
- if RUBY_VERSION >= '2.6.0'
18
- class ActionController::TestResponse < ActionDispatch::TestResponse
19
- def recycle!
20
- # hack to avoid MonitorMixin double-initialize error:
21
- @mon_mutex_owner_object_id = nil
22
- @mon_mutex = nil
23
- initialize
24
- end
25
- end
26
- end
27
-
28
-
29
- require 'appmap/rspec'
30
-
31
- # Requires supporting ruby files with custom matchers and macros, etc, in
32
- # spec/support/ and its subdirectories. Files matching `spec/**/*_spec.rb` are
33
- # run as spec files by default. This means that files in spec/support that end
34
- # in _spec.rb will both be required and run as specs, causing the specs to be
35
- # run twice. It is recommended that you do not name files matching this glob to
36
- # end with _spec.rb. You can configure this pattern with the --pattern
37
- # option on the command line or in ~/.rspec, .rspec or `.rspec-local`.
38
- #
39
- # The following line is provided for convenience purposes. It has the downside
40
- # of increasing the boot-up time by auto-requiring all files in the support
41
- # directory. Alternatively, in the individual `*_spec.rb` files, manually
42
- # require only the support files necessary.
43
- #
44
- # Dir[Rails.root.join('spec', 'support', '**', '*.rb')].each { |f| require f }
45
-
46
- # Checks for pending migrations and applies them before tests are run.
47
- # If you are not using ActiveRecord, you can remove these lines.
48
- begin
49
- ActiveRecord::Migration.maintain_test_schema!
50
- rescue ActiveRecord::PendingMigrationError => e
51
- puts e.to_s.strip
52
- exit 1
53
- end
54
- RSpec.configure do |config|
55
- # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
56
- config.fixture_path = "#{::Rails.root}/spec/fixtures"
57
-
58
- # RSpec Rails can automatically mix in different behaviours to your tests
59
- # based on their file location, for example enabling you to call `get` and
60
- # `post` in specs under `spec/controllers`.
61
- #
62
- # You can disable this behaviour by removing the line below, and instead
63
- # explicitly tag your specs with their type, e.g.:
64
- #
65
- # RSpec.describe UsersController, :type => :controller do
66
- # # ...
67
- # end
68
- #
69
- # The different available types are documented in the features, such as in
70
- # https://relishapp.com/rspec/rspec-rails/docs
71
- config.infer_spec_type_from_file_location!
72
-
73
- # Filter lines from Rails gems in backtraces.
74
- config.filter_rails_from_backtrace!
75
- # arbitrary gems may also be filtered via:
76
- # config.filter_gems_from_backtrace("gem name")
77
-
78
-
79
- config.before(:suite) do
80
- DatabaseCleaner.strategy = :transaction
81
- DatabaseCleaner.clean_with(:truncation)
82
- end
83
-
84
- config.around :each do |example|
85
- # Enable the use of 'return' from a guard
86
- -> {
87
- return example.run unless %i[model controller].member?(example.metadata[:type])
88
-
89
- DatabaseCleaner.cleaning do
90
- example.run
91
- end
92
- }.call
93
- end
94
-
95
- end
@@ -1,96 +0,0 @@
1
- # This file was generated by the `rails generate rspec:install` command. Conventionally, all
2
- # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
3
- # The generated `.rspec` file contains `--require spec_helper` which will cause
4
- # this file to always be loaded, without a need to explicitly require it in any
5
- # files.
6
- #
7
- # Given that it is always loaded, you are encouraged to keep this file as
8
- # light-weight as possible. Requiring heavyweight dependencies from this file
9
- # will add to the boot time of your test suite on EVERY test run, even for an
10
- # individual file that may not need all of that loaded. Instead, consider making
11
- # a separate helper file that requires the additional dependencies and performs
12
- # the additional setup, and require it from the spec files that actually need
13
- # it.
14
- #
15
- # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
16
- RSpec.configure do |config|
17
- # rspec-expectations config goes here. You can use an alternate
18
- # assertion/expectation library such as wrong or the stdlib/minitest
19
- # assertions if you prefer.
20
- config.expect_with :rspec do |expectations|
21
- # This option will default to `true` in RSpec 4. It makes the `description`
22
- # and `failure_message` of custom matchers include text for helper methods
23
- # defined using `chain`, e.g.:
24
- # be_bigger_than(2).and_smaller_than(4).description
25
- # # => "be bigger than 2 and smaller than 4"
26
- # ...rather than:
27
- # # => "be bigger than 2"
28
- expectations.include_chain_clauses_in_custom_matcher_descriptions = true
29
- end
30
-
31
- # rspec-mocks config goes here. You can use an alternate test double
32
- # library (such as bogus or mocha) by changing the `mock_with` option here.
33
- config.mock_with :rspec do |mocks|
34
- # Prevents you from mocking or stubbing a method that does not exist on
35
- # a real object. This is generally recommended, and will default to
36
- # `true` in RSpec 4.
37
- mocks.verify_partial_doubles = true
38
- end
39
-
40
- # This option will default to `:apply_to_host_groups` in RSpec 4 (and will
41
- # have no way to turn it off -- the option exists only for backwards
42
- # compatibility in RSpec 3). It causes shared context metadata to be
43
- # inherited by the metadata hash of host groups and examples, rather than
44
- # triggering implicit auto-inclusion in groups with matching metadata.
45
- config.shared_context_metadata_behavior = :apply_to_host_groups
46
-
47
- # The settings below are suggested to provide a good initial experience
48
- # with RSpec, but feel free to customize to your heart's content.
49
- =begin
50
- # This allows you to limit a spec run to individual examples or groups
51
- # you care about by tagging them with `:focus` metadata. When nothing
52
- # is tagged with `:focus`, all examples get run. RSpec also provides
53
- # aliases for `it`, `describe`, and `context` that include `:focus`
54
- # metadata: `fit`, `fdescribe` and `fcontext`, respectively.
55
- config.filter_run_when_matching :focus
56
-
57
- # Allows RSpec to persist some state between runs in order to support
58
- # the `--only-failures` and `--next-failure` CLI options. We recommend
59
- # you configure your source control system to ignore this file.
60
- config.example_status_persistence_file_path = "spec/examples.txt"
61
-
62
- # Limits the available syntax to the non-monkey patched syntax that is
63
- # recommended. For more details, see:
64
- # - http://rspec.info/blog/2012/06/rspecs-new-expectation-syntax/
65
- # - http://www.teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
66
- # - http://rspec.info/blog/2014/05/notable-changes-in-rspec-3/#zero-monkey-patching-mode
67
- config.disable_monkey_patching!
68
-
69
- # Many RSpec users commonly either run the entire suite or an individual
70
- # file, and it's useful to allow more verbose output when running an
71
- # individual spec file.
72
- if config.files_to_run.one?
73
- # Use the documentation formatter for detailed output,
74
- # unless a formatter has already been configured
75
- # (e.g. via a command-line flag).
76
- config.default_formatter = "doc"
77
- end
78
-
79
- # Print the 10 slowest examples and example groups at the
80
- # end of the spec run, to help surface which specs are running
81
- # particularly slow.
82
- config.profile_examples = 10
83
-
84
- # Run specs in random order to surface order dependencies. If you find an
85
- # order dependency and want to debug it, you can fix the order by providing
86
- # the seed, which is printed after each run.
87
- # --seed 1234
88
- config.order = :random
89
-
90
- # Seed global randomization in this process using the `--seed` CLI option.
91
- # Setting this allows you to use `--seed` to deterministically reproduce
92
- # test failures related to randomization by passing the same `--seed` value
93
- # as the one that triggered the failure.
94
- Kernel.srand config.seed
95
- =end
96
- end