hyrax
hyrax copied to clipboard
Feature test: new form - assign valkyrie work to valkyrie collection
Descriptive summary
Write a feature test that checks that a valkyrie resource work can be added to a resource collection through the new form.
Rationale
Users need to be able to put works in collections. This is a core feature and should work with Valkyrie resources.
Expected behavior
In the new form, there is a tab where relationships with the work can be specified. The form should allow the work to be added to a resource collection.
Actual behavior
If actual does not match expected, open an issue with details about what actual happened and what was expected.
Steps to reproduce the behavior
- Create a feature test
- Define a collection resource using let (hyrax_collection factory)
- In the test, create a new monograph resource work using the new form
- Go to the Relationships tab
- Select the collection resource created using let
- Save and verify that work was added to the collection as expected
Related work
Issue #4577 - Feature test: edit form - assign valkyrie work to valkyrie collection
See non-valkyrie features/create_work_spec.rb test