Skip to content

Commit

Permalink
fixtures: added subject type creation on load
Browse files Browse the repository at this point in the history
  • Loading branch information
alejandromumo authored and slint committed Mar 14, 2024
1 parent 23159bb commit 2fa125c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions invenio_rdm_records/fixtures/vocabularies.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,10 @@ def __init__(self, service_str, directory, id_, entry):
# Template methods
def pre_load(self, identity, ignore):
"""Actions taken before iteratively creating records."""
# Create the type first, if needed
super().pre_load(identity, ignore)

# Add schemes
for scheme in self.schemes():
id_ = f"{self._id}.{scheme['id']}"
if id_ not in ignore:
Expand Down

0 comments on commit 2fa125c

Please sign in to comment.