-
Notifications
You must be signed in to change notification settings - Fork 515
Conversation
Do not return undefined return null instead, aligned with other token helper methods
This method will be helpful in future commits, meanwhile use it internally
Add optional backward argument and change default direction
💯 |
it('should report assignment operator for "a=b"', function() { | ||
checker.configure({ requireSpaceBeforeBinaryOperators: ['='] }); | ||
assert(checker.checkString('a=b').getErrorCount() === 1); | ||
}); | ||
it('should not report assignment operator for "a = b" without option', function() { | ||
checker.configure({ requireSpaceBeforeBinaryOperators: [','] }); | ||
assert(checker.checkString('a= b').isEmpty()); | ||
assert(checker.checkString('a=b').isEmpty()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem to match the description
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed, thank you!
Add support and tests for all binary operators
Add support and tests for all binary operators
Add support and tests for all binary operators
Add support and tests for all binary operators
Add getPointerEntities method to token helper module, right now used only inside binary rules
@gustavohenke heads up, i think we could do |
Just a thought for this rule and other rules that have "giant arrays as values". Perhaps we should provide the |
+1 |
* Add binaryOperators attribute to utils module * Add true value as possible value to binary rules * Add one more test for binary rules to check true value * Update readme
@mikesherov done |
Binary rules now support and has tests for all binary operators. Some of those tests are dynamically generated, but write them explicitly is tedious and needless.
After that we need to update presets, remove doc for
*stickedOperators
rules and update the docs, then i think we would be ready for1.5
.