Commit Graph

24 Commits

Author SHA1 Message Date
luisramos0
86b0d71c7e Result of rubocop auto-correct and rebuilding rubocop_manual_todo 2019-05-28 12:57:29 +01:00
Pau Pérez Fabregat
a0c144fd0c Merge pull request #3415 from openfoodfoundation/feature/enterprise_fee_summary
[Enterprise Fee Summary] Merge "Enterprise Fee Summary" report to master
2019-02-12 13:58:47 +01:00
Kristina Lim
e14c60c1c1 Add RSpec matchers for flash messages 2019-02-10 22:08:18 +08:00
Kristina Lim
519a7d2ee6 Add datetime and integer array validator matchers 2019-02-08 21:26:36 +00:00
Maikel Linke
1407ae7778 Make TableMatcher match exactly, not part of row
Reverts dbf3a7aaaf9d458f99e14983ca9db2d4cbe4b564.

The reverted commit tried to avoid a 30 second delay by using
have_selector. While that was successful in reducing test time, it made
the matcher find rows that where not exactly the wanted row, but contained
text of the wanted row. This wasn't a problem until we experimented with
Chrome as test browser returns text on select boxes.

This commit makes the matcher precise again. We still have to deal with
the 30 second delay.
2019-01-16 16:21:30 +00:00
Rob Harrington
3b40ede0b8 Fix table row matchers
The matcher was silently failing on the check step (adding ~30 seconds to out specs each time it was used!), so I changed it to fail if the basic step does not succeed
2019-01-16 16:21:30 +00:00
Rob Harrington
c2432fab0b Use all_options_absent method instead of poorly written no_options_present
SAVES 30 SECONDS FOR EVERY SPEC THAT IS IT USED IN!
2019-01-16 16:21:30 +00:00
Maikel Linke
600c8fcd4c Send confirmation emails immediately
Using deferred methods on the user model breaks delayed jobs when the
user is deleted while the job still exists. We could create a proper job
referencing a user id for sending these emails instead. But since the
user has to wait for the confirmation email anyway, we can send it
within the current request. This should be revised if performance
becomes an issue.

Sending the email directly also has the advantage that we can tell the
user if emailing failed. See the following commits.

This change impacts a bunch of specs as we now need a working email
setup to create unconfirmed users. This commit introduces a custom
matcher to unify testing for confirmation emails.
2018-09-27 13:33:08 +10:00
Andy Palmer
131bf842a9 Update matchers to non-deprecated protocol 2017-11-10 08:47:12 +11:00
Rob Harrington
b277ff03ea Rubocop: Auto-correct Style/TrailingBlankLines offences 2017-06-23 16:49:07 +10:00
Rohan Mitchell
977ff7b35d Fix compatibility issues with new version of select2 2016-02-24 11:26:37 +11:00
Rohan Mitchell
76d4fbccf9 Use select2 for order cycle selection 2015-12-11 13:06:58 +11:00
Maikel Linke
ffa960b02e Merge remote-tracking branch 'origin/xero-report' into combined/xero-report_show-order-without-distributor 2015-06-05 13:48:24 +10:00
Rohan Mitchell
0737ac8da0 Write an rspec table matcher that gives informative error messages 2015-05-15 12:35:14 +10:00
Rob Harrington
7a4f0e214c Adding customers index view 2015-05-13 12:44:33 +10:00
Rob Harrington
1e1d52cc47 Adding 'selected' option to have_select2 matcher 2015-04-02 14:35:39 +11:00
Rohan Mitchell
4c9aa96b17 have_select2 can test for an exact set of options 2014-11-21 13:49:09 +11:00
Rohan Mitchell
d810388248 Add have_select2 capybara matcher 2014-11-21 13:49:09 +11:00
Rob Harrington
b5ef24bacb table matchers use capybara matchers rather than wait_until with micro-sleep 2014-09-24 16:18:59 +10:00
Rohan Mitchell
76d1754c32 Reorder helper method at bottom 2014-05-21 15:11:14 +10:00
Rohan Mitchell
6026a74c73 Table matcher have_table_row does not wait for full duration on should_not 2014-05-21 14:59:24 +10:00
Rohan Mitchell
ba7e29074f have_table_row waits 2014-05-21 11:29:11 +10:00
Rohan Mitchell
61af8204d9 Add spec matcher have_table_row 2014-05-21 11:29:11 +10:00
alexs
1ca306e09e Added RSpec matchers to test delegations. 2013-08-09 13:14:49 +10:00