def base_create_dep_objs(cls):
     """Create all objects that ProposalParticipant need."""
     prop3 = Proposals()
     TestProposals.base_create_dep_objs()
     prop3.from_hash(SAMPLE_PROPOSAL_HASH)
     prop3.save(force_insert=True)
     user = Users()
     TestUsers.base_create_dep_objs()
     user.from_hash(SAMPLE_USER_HASH)
     user.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Create all objects that InstrumentCustodian need."""
     inst = Instruments()
     TestInstruments.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTRUMENT_HASH)
     inst.save(force_insert=True)
     custodian = Users()
     TestUsers.base_create_dep_objs()
     custodian.from_hash(SAMPLE_USER_HASH)
     custodian.save(force_insert=True)
    def base_create_dep_objs(cls):
        """Build the object and make dependent user object."""
        submitter = Users()
        TestUsers.base_create_dep_objs()
        submitter.from_hash(SAMPLE_CREATOR_HASH)
        submitter.save(force_insert=True)

        uni_submitter = Users()
        uni_submitter.from_hash(SAMPLE_UNICODE_CREATOR_HASH)
        uni_submitter.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Create all objects that InstitutionPerson need."""
     inst = Institutions()
     TestInstitutions.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTITUTION_HASH)
     inst.save(force_insert=True)
     user1 = Users()
     TestUsers.base_create_dep_objs()
     user1.from_hash(SAMPLE_USER_HASH)
     user1.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Create all objects that UserGroup need."""
     member = Users()
     TestUsers.base_create_dep_objs()
     member.from_hash(SAMPLE_USER_HASH)
     member.save(force_insert=True)
     groups = Groups()
     TestGroups.base_create_dep_objs()
     groups.from_hash(SAMPLE_GROUP_HASH)
     groups.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Create all objects that Files depend on."""
     user = Users()
     TestUsers.base_create_dep_objs()
     user.from_hash(SAMPLE_USER_HASH)
     user.save(force_insert=True)
     inst = Institutions()
     TestInstitutions.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTITUTION_HASH)
     inst.save(force_insert=True)
Example #7
0
 def base_create_dep_objs(cls):
     """Build the object and make dependent user object."""
     auth_person = Users()
     TestUsers.base_create_dep_objs()
     auth_person.from_hash(SAMPLE_CREATOR_HASH)
     auth_person.save(force_insert=True)
     rel_trans = Transactions()
     TestTransactions.base_create_dep_objs()
     rel_trans.from_hash(SAMPLE_TRANSACTION_HASH)
     rel_trans.save(force_insert=True)
Example #8
0
 def base_create_dep_objs(cls):
     """Create all objects that InstitutionUser need."""
     rel = Relationships()
     TestRelationships.base_create_dep_objs()
     rel.from_hash(SAMPLE_RELATIONSHIP_HASH)
     rel.save(force_insert=True)
     inst = Institutions()
     TestInstitutions.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTITUTION_HASH)
     inst.save(force_insert=True)
     user1 = Users()
     TestUsers.base_create_dep_objs()
     user1.from_hash(SAMPLE_USER_HASH)
     user1.save(force_insert=True)
Example #9
0
 def base_create_dep_objs(cls):
     """Create all objects that ProjectUser need."""
     rel = Relationships()
     TestRelationships.base_create_dep_objs()
     rel.from_hash(SAMPLE_RELATIONSHIP_HASH)
     rel.save(force_insert=True)
     proj3 = Projects()
     TestProjects.base_create_dep_objs()
     proj3.from_hash(SAMPLE_PROJECT_HASH)
     proj3.save(force_insert=True)
     user = Users()
     TestUsers.base_create_dep_objs()
     user.from_hash(SAMPLE_USER_HASH)
     user.save(force_insert=True)
Example #10
0
 def base_create_dep_objs(cls):
     """Build the object and make dependent user object."""
     rel = Relationships()
     TestRelationships.base_create_dep_objs()
     rel.from_hash(SAMPLE_RELATIONSHIP_HASH)
     rel.save(force_insert=True)
     user3 = Users()
     TestUsers.base_create_dep_objs()
     user3.from_hash(SAMPLE_CREATOR_HASH)
     user3.save(force_insert=True)
     rel_trans = Transactions()
     TestTransactions.base_create_dep_objs()
     rel_trans.from_hash(SAMPLE_TRANSACTION_HASH)
     rel_trans.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Build the object and make dependent user object."""
     proj = Projects()
     TestProjects.base_create_dep_objs()
     proj.from_hash(SAMPLE_PROJECT_HASH)
     proj.save(force_insert=True)
     submitter = Users()
     TestUsers.base_create_dep_objs()
     submitter.from_hash(SAMPLE_SUBMITTER_HASH)
     submitter.save(force_insert=True)
     atool = AnalyticalTools()
     TestAnalyticalTools.base_create_dep_objs()
     atool.from_hash(SAMPLE_TOOL_HASH)
     atool.save(force_insert=True)
     trans = Transactions()
     TestTransactions.base_create_dep_objs()
     trans.from_hash(SAMPLE_TRANSACTION_HASH)
     trans.save(force_insert=True)
 def base_create_dep_objs(cls):
     """Build the object and make dependent user object."""
     submitter, _created = Users().get_or_create(
         id=SAMPLE_SUBMITTER_HASH['_id'])
     TestUsers.base_create_dep_objs()
     submitter.from_hash(SAMPLE_SUBMITTER_HASH)
     submitter.save()
     prop = Proposals()
     TestProposals.base_create_dep_objs()
     prop.from_hash(SAMPLE_PROPOSAL_HASH)
     prop.save(force_insert=True)
     inst = Instruments()
     TestInstruments.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTRUMENT_HASH)
     inst.save(force_insert=True)
     trans = Transactions()
     TestTransactions.base_create_dep_objs()
     trans.from_hash(SAMPLE_TRANSACTION_HASH)
     trans.save(force_insert=True)