Commit Graph

7 Commits

Author SHA1 Message Date
Daniel Colson 630aca4b87 Fix violations for latest version of standard 2021-02-20 17:22:31 -05:00
Daniel Colson 5f1a1de114 Run standardrb
This commit applies the changes from running `standardrb --fix`
2020-06-10 17:11:39 -04:00
Alejandro Dustet 5947e10578 Deprecate and move to Internal sequence methods
Why:
Another run of internal methods that should not be publicly
available from the base namespace.
This time the sequence involving methods were moved. It's worth noticing
that the ```Internal``` class is getting crowded. Maybe we can start
name-spacing the internal groups into modules under
```internal/sequence.rb``` ```internal/trait.rb``` and so on. Thoughts?

This PR:

- Moves the ```register_sequence```, ```sequence_by_name```,
```sequences``` and ```rewind_sequences``` to the
```FactoryBot::Internal``` module.
- Deprecates uses of ```sequence_by_name```, and ```sequences```
from the ```FactoryBot``` module.
- Refactor rewind sequences test to use spies

This is one of the steps towards fixing [this
issue](https://github.com/thoughtbot/factory_bot/pull/1285#1281)
2019-06-04 19:02:51 -04:00
Colin Ross a56b68bc9c Fix assorted RuboCop spacing volations (#1203)
* Alphabetize gem listing in various Gemfiles [Rubocop Bundler/OrderedGems]

* Fix alignment of if/else/end statement [Rubocop Layout/ElseAlignment]

* Method definitions should have a empty line between them [Rubocop Layout/EmptyLineBetweenDefs]

* Modules, Classes, and blocks should have an empty line around them [Rubocop]

Cops:
Layout/EmptyLinesAroundBlockBody
Layout/EmptyLinesAroundModuleBody
Layout/EmptyLinesAroundClassBody
Layout/EmptyLinesAroundAccessModifier

* Keep a blank line before and after access modifiers [Rubocop Layout/EmptyLinesAroundAccessModifier]

* Remove misc extra whitespace [Rubocop Layout/ExtraSpacing]

* Indent the first line of the right-hand-side of a multi-line assignment [Rubocop Layout/IndentAssignment]

* Remove extraneous whitespace [Rubocop]

Cops:
  Layout/IndentationWidth
  Layout/LeadingCommentSpace
  Layout/SpaceAroundEqualsInParameterDefault
  Layout/SpaceInsideArrayLiteralBrackets
  Layout/SpaceInsideBlockBraces
  Layout/SpaceInsideParens
  Layout/TrailingBlankLines

* Revert rubocop changes to gemfiles; exclude files from rubocop checks

The files in gemfiles/ are generated by Appraisal, so we shouldn't edit them. Instead, let's tell RuboCop to exclude this directory.
2018-09-27 21:35:05 -04:00
Daniel Colson 0473865b93 Remove static attributes
Co-authored-by: George Wambold <georgewambold@gmail.com>
2018-09-14 19:27:13 +00:00
Oli Peate 01d81f54b5 Remove unnecessary spec_helper requires
https://github.com/rspec/rspec/wiki#rspec
2018-05-21 18:03:28 +01:00
Avielle c716ce01b4 Replace 'girl' with 'bot' everywhere (#1051)
Also: add a deprecation warning to factory_girl, asking users to switch to
factory_bot

https://github.com/thoughtbot/factory_girl/issues/921
2017-10-20 15:20:28 -04:00