Commit graph

10 commits

Author SHA1 Message Date
Pierre de La Morinerie
9741108094 lib: remove the 'migrated' key on filters
In a9a4f6e2a8, a task to migrate
ProcedurePresentation's filters was added.

This task added a "migrated: true" key to all migrated filters.

Now that this task has run, we can safely remove the extra key.

In a previous version of this commit, the migration would fail for
invalid ProcedurePresentation records. This is now fixed.
2021-08-24 08:42:22 -05:00
Pierre de La Morinerie
6475cdff7a
Revert "Suppression de la clef "migrated": true sur les filtres des ProcedurePresentation" 2021-07-23 09:26:13 +02:00
Pierre de La Morinerie
38c4da2deb lib: document ProgressReport usage 2021-07-20 16:51:32 +02:00
Pierre de La Morinerie
2bb103b8bd task_helper: mark private methods 2019-05-29 11:48:41 +02:00
Pierre de La Morinerie
4d9cb0bb7a task_helper: fix duration formatting
If we don't convert the duration to utc, it starts at 01:00:00
2019-05-29 11:48:21 +02:00
Mathieu Magnin
dd27167c5d Enforce Timezone rule in Rubocop 2019-02-18 16:19:42 +01:00
gregoirenovel
a8f700b572 Enable the Style/FormatString cop 2018-12-19 13:56:10 +01:00
Frederic Merizen
84cfdcf617 [#2180] Fix edge cases for progress report 2018-12-07 16:45:14 +01:00
Frederic Merizen
c6c8bea095 [#2180] Progress reporter that doesn't crash 2018-12-07 15:30:10 +01:00
Pierre de La Morinerie
790704ef58 tasks: silence output of tasks during tests
Currently, when running specs, the output of rake tasks is spamming
the tests results.

This PR configures Rake so that it runs in quiet mode during specs. This
disables the internal messages of rake during tests.

However our own `puts` also need to be conditionned to the verbosity of
rake. Using a simple `rake_puts` helper allows the info messages to be
displayed when running the rake task manually, but not during tests.

Before:

```
$ bin/rspec spec/lib/rake
Randomized with seed 6544
1 Mails::ClosedMail to clean
cleaning Mails::ClosedMail #1
1 Mails::InitiatedMail to clean
cleaning Mails::InitiatedMail #1
1 Mails::ReceivedMail to clean
cleaning Mails::ReceivedMail #1
1 Mails::RefusedMail to clean
cleaning Mails::RefusedMail #1
1 Mails::WithoutContinuationMail to clean
cleaning Mails::WithoutContinuationMail #1
.....Champ 0/1
.Champ 0/1
.
```

After:

```
$ bin/rspec spec/lib/rake

Randomized with seed 6544
.......
```
2018-06-13 11:05:15 +02:00