0f4beab0fb
DEV: Update the rubocop-discourse gem
...
This enables cops related to RSpec `subject`.
See https://github.com/discourse/rubocop-discourse/pull/32
2023-06-26 11:41:52 +02:00
055310cea4
DEV: Apply syntax_tree formatting to plugins/*
2023-01-07 11:11:37 +00:00
493d437e79
Add RSpec 4 compatibility ( #17652 )
...
* Remove outdated option
04078317ba
* Use the non-globally exposed RSpec syntax
https://github.com/rspec/rspec-core/pull/2803
* Use the non-globally exposed RSpec syntax, cont
https://github.com/rspec/rspec-core/pull/2803
* Comply to strict predicate matchers
See:
- https://github.com/rspec/rspec-expectations/pull/1195
- https://github.com/rspec/rspec-expectations/pull/1196
- https://github.com/rspec/rspec-expectations/pull/1277
2022-07-28 10:27:38 +08:00
5d97286fa7
FEATURE: Allow single option polls ( #8853 )
2020-02-05 08:03:27 -06:00
9e3fc1111d
FIX: Add a blank poll options validation ( #8652 )
...
Before, saving a post with a blank poll option resulted in error 500.
2020-01-03 15:09:36 +01:00
30990006a9
DEV: enable frozen string literal on all files
...
This reduces chances of errors where consumers of strings mutate inputs
and reduces memory usage of the app.
Test suite passes now, but there may be some stuff left, so we will run
a few sites on a branch prior to merging
2019-05-13 09:31:32 +08:00
e49bcebb35
FIX: Validate poll arguments. ( #6740 )
...
* FIX: Validate number poll.
* FEATURE: Poll's min can be 0.
* FIX: Fix URL to user profile.
2018-12-31 10:48:30 +01:00
4459665dee
REFACTOR: use tables instead of custom fields for polls ( #6359 )
...
Co-authored-by: Guo Xiang Tan <tgx_world@hotmail.com >
2018-11-19 14:50:00 +01:00
5012d46cbd
Add rubocop to our build. ( #5004 )
2017-07-28 10:20:09 +09:00
1661a8745b
correct issues with poll specs
...
fixes regression where an error message is missing from a poll
with one option
2017-07-17 17:44:48 -04:00
2f14a81fa4
FIX: min
setting should be greater than 0 for multiple type polls.
2016-06-07 10:48:06 +08:00
a849fae5ee
Add specs for polls ( #4246 )
...
* Extract validation logic into a service object.
* Extract logic for updating polls custom fields into a service object.
* Use `strip_heredoc` instead.
* FIX: Polls do not update when configuration has been changed.
2016-06-06 17:04:56 +02:00