Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/mauRepo/MolesManager/trunk/src/libs/migration/tests/test_utils.py@8198
Line | |
---|
1 | ''' |
---|
2 | Created on 31 Mar 2012 |
---|
3 | |
---|
4 | @author: mnagni |
---|
5 | ''' |
---|
6 | from ea_model.ceda_metadatamodel.ceda_observationcollection.ceda_observationcollection import CEDA_ObservationCollection |
---|
7 | from libs.migration.processor.commons import createMD_Identifier,\ |
---|
8 | createCI_Citation |
---|
9 | |
---|
10 | def createObservationCollection(): |
---|
11 | ''' |
---|
12 | Creates a CEDA_ObservationCollection with the following data: |
---|
13 | oc.identifier[0].code = 'test_code' |
---|
14 | oc.identifier[0].authority.title = 'test_title' |
---|
15 | ''' |
---|
16 | observationCollection = CEDA_ObservationCollection() |
---|
17 | auth = createCI_Citation('test_title') |
---|
18 | i_identifier = createMD_Identifier(code = 'test_code', authority=auth) |
---|
19 | observationCollection.identifier.append(i_identifier) |
---|
20 | return observationCollection |
---|
Note: See
TracBrowser
for help on using the repository browser.