Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix flaky GraduationJob tests (#2185)
All tests in the GraduationJob test group are periodically failing with the same error: ``` ActiveRecord::RecordNotFound: Couldn't find Hyrax::PermissionTemplate ./lib/workflow_setup.rb:156:in `block in everyone_can_deposit_everywhere' ./lib/workflow_setup.rb:154:in `everyone_can_deposit_everywhere' ./lib/workflow_setup.rb:44:in `setup' ./spec/jobs/graduation_job_with_embargo_spec.rb:46:in `block (3 levels) in <top (required)>' ``` This failure is occuring in the workflow setup called in the `before` block for the test group. It appears that depending on the randomized order of other tests, the AdminSets and Workflow may be left in a state incompatible with the workflow setup for this test group, causing the setup to silently fail. Explicitly resetting Fedora to a clean state allows the workflow setup to run successfully and leave Workflows in the state expected by the rest of the test group.
- Loading branch information