Pedro Paiva
73deafdf89
Remove use_before_filter, use_after_filter and use_around_filter matchers ( #1431 )
2021-03-21 01:10:32 -03:00
Kapil Sachdev
b7e02184d9
fix(rubocop): Fix Layout/LineLength
...
- bump rubocop to v1.0
- Fix Layout/MultilineAssignmentLayout and other remaining offences
- Exculde appraisal generated gemfiles in rubocop
- Replace NON_NUMERIC_VALUE constant with instance method against
failing test case in rails <= 5.1 and postgres adapter.
This is a defect in rails where a frozen string is modified in
https://github.com/rails/rails/blob/v5.1.7/activerecord/lib/active_record/connection_adapters/postgresql/oid/money.rb#L25
2020-11-03 10:05:25 -07:00
Elliot Winkler
6ea9afc106
Drop legacy callback matchers under Rails 5
...
Rails 5 dropped the legacy controller callbacks `before_filter`,
`after_filter` and `around_filter`, so the matchers for these callbacks
are useless.
2017-09-26 17:17:18 -05:00
Elliot Winkler
afa6a7b666
Update RSpec test style across docs
...
Instead of using
describe Foo do
# ...
end
use
RSpec.describe Foo, type: :model do
# ...
end
instead. This is not exactly official, as the former style still works,
but the latter style is highly suggested in RSpec documentation and the
like, so this is what people are used to.
[ci skip]
2016-06-15 18:02:07 -06:00
Elliot Winkler
142366ef16
Refer to Minitest in docs over Test::Unit
...
Minitest has been used instead of Test::Unit for quite some time now,
let's get with the times.
[ci skip]
2015-09-30 13:18:23 -06:00
Mauro George
32c0e62596
Drop support for RSpec 2
2015-09-22 13:12:46 -06:00
Sergey Kuchmistov
198570db2c
Prefer protected over private attributes
2014-06-27 14:41:54 -06:00
Elliot Winkler
c22d7c89e0
Extract examples in README to inline documentation
2014-06-20 16:41:27 -06:00
Elliot Winkler
025dfdc432
Fix callback matchers to take controller instances
...
Controller matchers operate on instances of controllers, not controller
classes themselves.
2014-04-16 12:56:30 -06:00
Damian Galarza and Harry Schwartz
b5083467bc
Add CallbackMatcher for ActionController
...
Matcher for checking if a filter / action callback is in place within a
controller.
Example:
```ruby
describe UserController do
it { should use_before_filter(:authenticate_user!) }
end
```
2014-03-07 10:54:40 -05:00