samvera / hyrax

Hyrax is a Ruby on Rails Engine built by the Samvera community. Hyrax provides a foundation for creating many different digital repository applications.
http://hyrax.samvera.org/
Apache License 2.0
182 stars 122 forks source link

Change && to if #6860

Closed kirkkwang closed 16 hours ago

kirkkwang commented 3 days ago

In the case of a GenericWorkResource the #hydra_model method would still return GenericWork because the first condition evaluated to true instead.

github-actions[bot] commented 3 days ago

Test Results

    17 files  ±0      17 suites  ±0   2h 18m 37s :stopwatch: +33s  6 705 tests ±0   6 408 :white_check_mark: ±0  297 :zzz: ±0  0 :x: ±0  13 178 runs  ±0  12 783 :white_check_mark: ±0  395 :zzz: ±0  0 :x: ±0 

Results for commit fa945372. ± Comparison against base commit 814fdccc.

This pull request removes 275 and adds 275 tests. Note that renamed tests count towards both. ``` spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to destroy AdminSet: 6647fff3-ff17-4d09-bc28-7e006b32b6be spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to destroy Hyrax::AdministrativeSet: 165a4691-1b93-4709-9d3b-7cff0c04a104 spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to edit AdminSet: b959c4a9-e3ef-4527-a9ae-2bb6c6f00a7e spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to edit Hyrax::AdministrativeSet: f8c6191d-75b9-48da-bafd-5e93bfd3f0d1 spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to update AdminSet: d3b089ae-e1bb-4152-86b1-3cba70e1b5d7 spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to update Hyrax::AdministrativeSet: e20cc236-4bf5-43c2-b804-92db27f1d1e5 … ``` ``` spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to create # spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to destroy AdminSet: ef0fc783-dfa0-4e5a-87f0-4fb0b982a9cb spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to destroy Hyrax::AdministrativeSet: e54c3706-caba-4022-b953-87945b681c54 spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to edit AdminSet: aaa65dad-4625-4ca2-9b8d-cced70a24543 spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to edit Hyrax::AdministrativeSet: d333642a-d0c4-48d7-b81e-e710f966b94c spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to update AdminSet: 03b2e646-53c7-4d9d-aa9f-654beae972ec spec.abilities.ability_spec ‑ Hyrax::Ability AdminSets and PermissionTemplates a user without edit access is expected not to be able to update Hyrax::AdministrativeSet: 5ae44940-da76-45e4-a549-e84ff9e6f08a … ```

:recycle: This comment has been updated with latest results.