TELEM_FILE_TWO = "E00000002.DAT" # Fill in driver details DataSetTestCase.initialize( driver_module="mi.dataset.driver.WFP_ENG.STC_IMODEM.driver", driver_class="WFP_ENG__STC_IMODEM_DataSetDriver", agent_resource_id="123xyz", agent_name="Agent007", agent_packet_config=WFP_ENG__STC_IMODEM_DataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: "wfp_eng__stc_imodem", DataSourceConfigKey.HARVESTER: { DataTypeKey.WFP_ENG_STC_IMODEM_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: "E*.DAT", DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.WFP_ENG_STC_IMODEM_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: "E*.DAT", DataSetDriverConfigKeys.FREQUENCY: 1, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.WFP_ENG_STC_IMODEM_RECOVERED: {}, DataTypeKey.WFP_ENG_STC_IMODEM_TELEMETERED: {}, }, }, ) RECOV_PARTICLES = ( WfpEngStcImodemStatusRecoveredDataParticle,
from mi.dataset.driver.optaa_ac.mmp_cds.driver import OptaaAcMmpCdsDataSetDriver from mi.dataset.parser.optaa_ac_mmp_cds import OptaaAcMmpCdsParserDataParticle, DataParticleType from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent # Driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.optaa_ac.mmp_cds.driver', driver_class='OptaaAcMmpCdsDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=OptaaAcMmpCdsDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'optaa_ac_mmp_cds', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: '*.mpk', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ###############################################################################
RECOV_TEST_DIR = '/tmp/dsatest2' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.dofst_k.wfp.driver', driver_class='DofstKWfpDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=DofstKWfpDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'dofst_k_wfp', DataSourceConfigKey.HARVESTER: { DataTypeKey.DOFST_K_WFP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_TEST_DIR, DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.DOFST_K_WFP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_TEST_DIR, DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.DOFST_K_WFP_TELEMETERED: {}, DataTypeKey.DOFST_K_WFP_RECOVERED: {} } }) RECOV_PARTICLES = (DofstKWfpRecoveredDataParticle, DofstKWfpRecoveredMetadataParticle)
from mi.dataset.parser.test.test_glider import GliderParserUnitTestCase from mi.dataset.harvester import AdditiveSequentialFileHarvester from mi.dataset.driver.moas.gl.ctdgv.driver import CTDGVDataSetDriver from mi.dataset.parser.glider import GgldrCtdgvDelayedDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import CapabilityType from interface.objects import AgentCapability from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module="mi.dataset.driver.moas.gl.ctdgv.driver", driver_class="CTDGVDataSetDriver", agent_resource_id="123xyz", agent_name="Agent007", agent_packet_config=CTDGVDataSetDriver.stream_config(), startup_config={"harvester": {"directory": "/tmp/dsatest", "pattern": "*.mrg", "frequency": 1}, "parser": {}}, ) SAMPLE_STREAM = "ggldr_ctdgv_delayed" ############################################################################### # UNIT TESTS # # Device specific unit tests are for # # testing device specific capabilities # ############################################################################### @attr("INT", group="mi") class IntegrationTest(DataSetIntegrationTestCase): def test_get(self): """
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.adcpa.driver', driver_class='AdcpaDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=AdcpaDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'moas_gl_adcpa', DataSourceConfigKey.HARVESTER: { DataTypeKey.ADCPA_INSTRUMENT: { DataSetDriverConfigKeys.DIRECTORY: DIR_ADCPA_LIVE, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.ADCPA_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_ADCPA_RECOVERED, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.ADCPA_INSTRUMENT: {}, DataTypeKey.ADCPA_RECOVERED: {} } } )
from mi.core.instrument.instrument_driver import DriverEvent from mi.dataset.dataset_driver import DataSourceConfigKey, DataSetDriverConfigKeys from mi.dataset.driver.flord_l_wfp.sio_mule.driver import FlordLWfpSioMuleDataSetDriver from mi.dataset.parser.flord_l_wfp_sio_mule import FlordLWfpSioMuleParserDataParticle, DataParticleType # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.flord_l_wfp.sio_mule.driver', driver_class='FlordLWfpSioMuleDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = FlordLWfpSioMuleDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'flord_l_wfp_sio_mule', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: 'TestData.dat', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM = 'flord_l_wfp_instrument' # The integration and qualification tests generated here are suggested tests, # but may not be enough to fully test your driver. Additional tests should be # written as needed.
DIR_FLORT_KN_INSTRUMENT_RECOVERED = '/tmp/flort/dsatest2' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.FLORT_KN.STC_IMODEM.driver', driver_class='FLORT_KN_STC_IMODEM_DataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=FLORT_KN_STC_IMODEM_DataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'flort_kn_stc_imodem', DataSourceConfigKey.HARVESTER: { DataParticleType.FLORT_KN_INSTRUMENT_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_FLORT_KN_LIVE, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataParticleType.FLORT_KN_INSTRUMENT_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_FLORT_KN_INSTRUMENT_RECOVERED, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataParticleType.FLORT_KN_INSTRUMENT_TELEMETERED: {}, DataParticleType.FLORT_KN_INSTRUMENT_RECOVERED: {} } }) ###############################################################################
from pyon.agent.agent import ResourceAgentState from interface.objects import CapabilityType from interface.objects import AgentCapability from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.wfp.ctdpfk.driver', driver_class="WfpCTDPFKDataSetDriver", agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=WfpCTDPFKDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: '*.TXT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} }) SAMPLE_STREAM = 'ctdpfk_parsed' ############################################################################### # INT TESTS # # Device specific integration tests are for # # testing device specific capabilities # ###############################################################################
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.WFP_ENG.STC_IMODEM.driver', driver_class='WFP_ENG__STC_IMODEM_DataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=WFP_ENG__STC_IMODEM_DataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'wfp_eng__stc_imodem', DataSourceConfigKey.HARVESTER: { DataTypeKey.WFP_ENG_STC_IMODEM_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.WFP_ENG_STC_IMODEM_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.WFP_ENG_STC_IMODEM_RECOVERED: {}, DataTypeKey.WFP_ENG_STC_IMODEM_TELEMETERED: {}, } } )
DIR_ADCPA_RECOVERED = '/tmp/dsatest2' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.adcpa.driver', driver_class='AdcpaDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=AdcpaDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'moas_gl_adcpa', DataSourceConfigKey.HARVESTER: { DataTypeKey.ADCPA_INSTRUMENT: { DataSetDriverConfigKeys.DIRECTORY: DIR_ADCPA_LIVE, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.ADCPA_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_ADCPA_RECOVERED, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.ADCPA_INSTRUMENT: {}, DataTypeKey.ADCPA_RECOVERED: {} } }) # The integration and qualification tests generated here are suggested tests, # but may not be enough to fully test your driver. Additional tests should be
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.dosta_ln.wfp_sio_mule.driver', driver_class='DostaLnWfpSioMuleDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = DostaLnWfpSioMuleDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'dosta_ln_wfp_sio_mule', DataSourceConfigKey.HARVESTER: { DataSourceKey.DOSTA_LN_WFP_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node58p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceKey.DOSTA_LN_WFP: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataSourceKey.DOSTA_LN_WFP_SIO_MULE: {}, DataSourceKey.DOSTA_LN_WFP: {} } } )
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.flort_dj.dcl.driver', driver_class='FlortDjDclDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = FlortDjDclDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataTypeKey.FLORT_DJ_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.flort*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.FLORT_DJ_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TEL_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.flort*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.FLORT_DJ_RECOVERED: {}, DataTypeKey.FLORT_DJ_TELEMETERED: {} } } )
RECOV_DIR = '/tmp/adcps_sio_recov/dsatest' # Fill in the blanks to initialize data set test case DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.adcp.driver', driver_class='MflmADCPSDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=MflmADCPSDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'adcps', DataSourceConfigKey.HARVESTER: { DataSourceKey.ADCPS_JLN_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 5 }, DataSourceKey.ADCPS_JLN: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataSourceKey.ADCPS_JLN_SIO_MULE: {}, DataSourceKey.ADCPS_JLN: {} } }) ############################################################################### # INTEGRATION TESTS #
from mi.dataset.parser.vel3d_a_mmp_cds import Vel3dAMmpCdsParserDataParticle, DataParticleType from nose.plugins.attrib import attr from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.vel3d_a.mmp_cds.driver', driver_class='Vel3dAMmpCdsDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=Vel3dAMmpCdsDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'vel3d_a_mmp_cds', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: '*.mpk', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} }) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ############################################################################### @attr('INT', group='mi')
from mi.dataset.driver.mflm.dosta.driver import MflmDOSTADDataSetDriver from mi.dataset.parser.dostad import DostadParserDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.dosta.driver', driver_class='MflmDOSTADDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmDOSTADDataSetDriver.stream_config(), startup_config = { 'harvester': { 'directory': '/tmp/dsatest', 'pattern': 'node59p1.dat', 'frequency': 1, }, 'parser': {} } ) SAMPLE_STREAM = 'dostad_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ###############################################################################
from interface.objects import AgentCapability from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DATADIR = '/tmp/dsatest' STORAGEDIR = '/tmp/stored_dsatest' RESOURCE_ID = 'ctdgv' DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.ctdgv.driver', driver_class="CTDGVDataSetDriver", agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=CTDGVDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: RESOURCE_ID, DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: DATADIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: STORAGEDIR, DataSetDriverConfigKeys.PATTERN: '*.mrg', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} }) SAMPLE_STREAM = 'ggldr_ctdgv_delayed' ############################################################################### # UNIT TESTS # # Device specific unit tests are for # # testing device specific capabilities #
from mi.core.log import get_logger log = get_logger() from mi.idk.dataset.unit_test import DataSetTestCase from mi.idk.dataset.unit_test import DataSetUnitTestCase from mi.idk.dataset.unit_test import DataSetIntegrationTestCase from mi.idk.dataset.unit_test import DataSetQualificationTestCase DataSetTestCase.initialize(driver_module='mi.dataset.driver.mflm.ctd.driver', driver_class="MflmCTDMODataSetDriver", agent_preload_id='EDA_NOSE_CTD', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=['nose_ctd_external'], startup_config={ 'harvester': { 'directory': '/tmp/dsatest', 'pattern': '*.000', 'frequency': 1, }, 'parser': {} }) class SampleData(object): TEST_DATA_1 = """ cd3e3c2f53616d706c65446174613e0d0a3c45786563757465642f3e0d0a03014354313233373230305f303039436235314543354239365f35365f3041343802 4321abe596d7bd1f41fa7e190d1d21da659c18282241fa7e190d14383d469c4af80c41fa7e190d1324075588a0991f41fa7e190d36248f258e9b131d41fa7e19 0d3e234eb5842c392341fa7e190d3c2f14f61b6ff51041fa7e190d3423b2059240272641fa7e190d0f25e5d59f0f971641fa7e190d383857c69d9a140b41fa7e 190d39360a40c355eb0a41fa7e190d1a21c4b59025741841fa7e190d0301434f313233373230305f303034387535314543354239365f35375f304541330243ff
from mi.dataset.driver.issmcnsm.dosta.driver import IssmCnsmDOSTADDataSetDriver from mi.dataset.parser.issmcnsm_dostad import Issmcnsm_dostadParserDataParticle RESOURCE_ID = 'dostad' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.issmcnsm.dosta.driver', driver_class='IssmCnsmDOSTADDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = IssmCnsmDOSTADDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: RESOURCE_ID, DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: '*.dosta.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM = 'issmcnsm_dostad_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for #
VelptJCsppInstrumentTelemeteredDataParticle) # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.velpt_j.cspp.driver', driver_class='VelptJCsppDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=VelptJCsppDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'velpt_j_cspp', DataSourceConfigKey.HARVESTER: { DataTypeKey.VELPT_J_CSPP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEMETERED_DIR, DataSetDriverConfigKeys.PATTERN: '*.txt', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.VELPT_J_CSPP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOVERED_DIR, DataSetDriverConfigKeys.PATTERN: '*.txt', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.VELPT_J_CSPP_TELEMETERED: {}, DataTypeKey.VELPT_J_CSPP_RECOVERED: {} } }) ###############################################################################
from pyon.agent.agent import ResourceAgentState from interface.objects import CapabilityType from interface.objects import AgentCapability from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.wfp.paradk.driver', driver_class="WfpPARADKDataSetDriver", agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = WfpPARADKDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: '*.TXT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM='wfp_parad_k_parsed' ############################################################################### # INT TESTS # # Device specific integration tests are for # # testing device specific capabilities #
DIR_FLCDR = '/tmp/flntu/flcdr' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.flntu_x.mmp_cds.driver', driver_class='FlntuXMmpCdsDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=FlntuXMmpCdsDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'flntu_x_mmp_cds', DataSourceConfigKey.HARVESTER: { DataParticleType.FLNTU_X_MMP_CDS_INSTRUMENT: { DataSetDriverConfigKeys.DIRECTORY: DIR_FLNTU, DataSetDriverConfigKeys.PATTERN: '*.mpk', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataParticleType.FLCDR_X_MMP_CDS_INSTRUMENT: { DataSetDriverConfigKeys.DIRECTORY: DIR_FLCDR, DataSetDriverConfigKeys.PATTERN: '*.mpk', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataParticleType.FLNTU_X_MMP_CDS_INSTRUMENT: {}, DataParticleType.FLCDR_X_MMP_CDS_INSTRUMENT: {} } }) ###############################################################################
TELEM_DIR = '/tmp/dsatest1' RECOV_DIR = '/tmp/dsatest2' DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.flort.driver', driver_class='MflmFLORTDDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=MflmFLORTDDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.HARVESTER: { DataSourceKey.FLORT_DJ_SIO_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, DataSourceKey.FLORT_DJ_SIO_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: 'FLO*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, }, DataSourceConfigKey.PARSER: { DataSourceKey.FLORT_DJ_SIO_TELEMETERED: {}, DataSourceKey.FLORT_DJ_SIO_RECOVERED: {} } }) ###############################################################################
DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.ctd.driver', driver_class="MflmCtdmoDataSetDriver", agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmCtdmoDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataTypeKey.CTDMO_GHQR_CO: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: 'CTD*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.CTDMO_GHQR_CT: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: 'SBE37-IM_*.hex', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.CTDMO_GHQR_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TEL_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, } }, DataSourceConfigKey.PARSER: { DataTypeKey.CTDMO_GHQR_CO: { CtdmoStateKey.INDUCTIVE_ID: 55 }, DataTypeKey.CTDMO_GHQR_CT: { CtdmoStateKey.INDUCTIVE_ID: 55, CtdmoStateKey.SERIAL_NUMBER: 03710261 }, DataTypeKey.CTDMO_GHQR_SIO_MULE: { CtdmoStateKey.INDUCTIVE_ID: 55 } } } )
from mi.dataset.dataset_driver import DataSourceConfigKey from mi.dataset.dataset_driver import DriverParameter from mi.dataset.driver.moas.gl.flord.driver import FLORDDataSetDriver from mi.dataset.parser.glider import GgldrFlordDelayedDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.flord.driver', driver_class="FLORDDataSetDriver", agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=FLORDDataSetDriver.stream_config(), startup_config={ 'harvester': { 'directory': '/tmp/dsatest', 'pattern': '*.mrg', 'frequency': 1, }, 'parser': {} }) SAMPLE_STREAM = 'ggldr_flord_delayed' ############################################################################### # UNIT TESTS # # Device specific unit tests are for # # testing device specific capabilities # ###############################################################################
AdcpsJlnStcMetadataParserDataParticle) # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.adcps_jln.stc.driver', driver_class='AdcpsJlnStcDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=AdcpsJlnStcDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'adcps_jln_stc', DataSourceConfigKey.HARVESTER: { DataTypeKey.ADCPS_JLN_STC: { DataSetDriverConfigKeys.DIRECTORY: ADCPS_JLN_TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'adcp[st]_*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.ADCPS_JLN: { DataSetDriverConfigKeys.DIRECTORY: ADCPS_JLN_RECOVERED_DIR, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.ADCPS_JLN_STC: {}, DataTypeKey.ADCPS_JLN: {} } }) ############################################################################### # INTEGRATION TESTS #
from mi.dataset.driver.mflm.phsen.driver import MflmPHSENDataSetDriver from mi.dataset.parser.phsen import PhsenParserDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.phsen.driver', driver_class='MflmPHSENDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmPHSENDataSetDriver.stream_config(), startup_config = { 'harvester': { 'directory': '/tmp/dsatest', 'pattern': 'node59p1.dat', 'frequency': 1, }, 'parser': {} } ) SAMPLE_STREAM = 'phsen_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ###############################################################################
MopakOStcAccelParserDataParticle, MopakOStcRateParserDataParticle, DataParticleType, ) from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent # Fill in driver details DataSetTestCase.initialize( driver_module="mi.dataset.driver.MOPAK.STC.driver", driver_class="MopakOStcDataSetDriver", agent_resource_id="123xyz", agent_name="Agent007", agent_packet_config=MopakOStcDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: "mopak_o_stc", DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: "/tmp/dsatest", DataSetDriverConfigKeys.PATTERN: "*.mopak.log", DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {}, }, ) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ############################################################################### @unittest.skip("In process of merging with RTE")
from mi.dataset.driver.issmcnsm.dosta.driver import IssmCnsmDOSTADDataSetDriver from mi.dataset.parser.issmcnsm_dostad import Issmcnsm_dostadParserDataParticle RESOURCE_ID = 'dostad' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.issmcnsm.dosta.driver', driver_class='IssmCnsmDOSTADDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=IssmCnsmDOSTADDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: RESOURCE_ID, DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: '*.dosta.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataSourceConfigKey.PARSER: {} }) SAMPLE_STREAM = 'issmcnsm_dostad_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for #
from pyon.agent.agent import ResourceAgentState from interface.objects import CapabilityType from interface.objects import AgentCapability from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.issm.nutnrb.driver', driver_class='IssmRiNUTNRBDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = IssmRiNUTNRBDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: '*.log', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM = 'nutnrb_parsed' ############################################################################### # INT TESTS # # Device specific integration tests are for # # testing device specific capabilities #
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.dofst_k.wfp.driver', driver_class='DofstKWfpDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = DofstKWfpDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'dofst_k_wfp', DataSourceConfigKey.HARVESTER: { DataSourceKey.DOFST_K_WFP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_TEST_DIR, DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceKey.DOFST_K_WFP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_TEST_DIR, DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataSourceKey.DOFST_K_WFP_TELEMETERED: {}, DataSourceKey.DOFST_K_WFP_RECOVERED: {} } } )
from mi.dataset.parser.dostad import DostadParserDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.dosta.driver', driver_class='MflmDOSTADDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmDOSTADDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dsatest', DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM = 'dostad_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities #
from mi.dataset.driver.moas.gl.engineering.driver import EngDataSetDriver from mi.dataset.parser.glider import GgldrEngDelayedDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.engineering.driver', driver_class="EngDataSetDriver", agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = EngDataSetDriver.stream_config(), startup_config = { 'harvester': { 'directory': '/tmp/dsatest', 'pattern': '*.mrg', 'frequency': 1, }, 'parser': {} } ) SAMPLE_STREAM='ggldr_eng_delayed' ############################################################################### # UNIT TESTS # # Device specific unit tests are for # # testing device specific capabilities #
# Driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.ctdpf_j.cspp.driver', driver_class='CtdpfJCsppDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=CtdpfJCsppDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'ctdpf_j_cspp', DataSourceConfigKey.HARVESTER: { DataTypeKey.CTDPF_J_CSPP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_CTDPF_TELEMETERED, DataSetDriverConfigKeys.PATTERN: CTDPF_TEL_PATTERN, DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.CTDPF_J_CSPP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_CTDPF_RECOVERED, DataSetDriverConfigKeys.PATTERN: CTDPF_REC_PATTERN, DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.CTDPF_J_CSPP_TELEMETERED: {}, DataTypeKey.CTDPF_J_CSPP_RECOVERED: {} } } ) REC_PARTICLES = (CtdpfJCsppMetadataRecoveredDataParticle,
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.spkir_abj.dcl.driver', driver_class='SpkirAbjDclDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = SpkirAbjDclDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataTypeKey.SPKIR_ABJ_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.spkir*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.SPKIR_ABJ_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TEL_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.spkir*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.SPKIR_ABJ_RECOVERED: {}, DataTypeKey.SPKIR_ABJ_TELEMETERED: {} } } )
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.PARAD_K.STC_IMODEM.driver', driver_class='PARAD_K_STC_IMODEM_DataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = PARAD_K_STC_IMODEM_DataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'parad_k_stc_imodem', DataSourceConfigKey.HARVESTER: { DataTypeKey.PARAD_K_STC: { DataSetDriverConfigKeys.DIRECTORY: DIR_TEL, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.PARAD_K_STC_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_REC, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.PARAD_K_STC: {}, DataTypeKey.PARAD_K_STC_RECOVERED: {} } } )
REC_STREAM = DataParticleType.REC_INSTRUMENT_PARTICLE TEL_STREAM = DataParticleType.TEL_INSTRUMENT_PARTICLE # Fill in driver details DataSetTestCase.initialize( driver_module="mi.dataset.driver.dosta_abcdjm.dcl.driver", driver_class="DostaAbcdjmDclDataSetDriver", agent_resource_id="123xyz", agent_name="Agent007", agent_packet_config=DostaAbcdjmDclDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.HARVESTER: { DataTypeKey.DOSTA_ABCDJM_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: "[0-9]*.dosta*.log", DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.DOSTA_ABCDJM_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TEL_DIR, DataSetDriverConfigKeys.PATTERN: "[0-9]*.dosta*.log", DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, }, DataSourceConfigKey.PARSER: {DataTypeKey.DOSTA_ABCDJM_RECOVERED: {}, DataTypeKey.DOSTA_ABCDJM_TELEMETERED: {}}, }, ) # The integration and qualification tests generated here are suggested tests, # but may not be enough to fully test your driver. Additional tests should be # written as needed.
from mi.dataset.dataset_driver import DriverParameter from mi.dataset.dataset_driver import DataSourceConfigKey, DataSetDriverConfigKeys from mi.dataset.driver.ctdpf_ckl.wfp.driver import CtdpfCklWfpDataSetDriver from mi.dataset.parser.ctdpf_ckl_wfp import CtdpfCklWfpParserDataParticle, DataParticleType from mi.dataset.parser.wfp_c_file_common import StateKey # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.ctdpf_ckl.wfp.driver', driver_class='CtdpfCklWfpDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = CtdpfCklWfpDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'ctdpf_ckl_wfp', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) # The integration and qualification tests generated here are suggested tests, # but may not be enough to fully test your driver. Additional tests should be # written as needed. ###############################################################################
RECOVERED_DIR = '/tmp/recoveredtest' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.phsen.driver', driver_class='MflmPHSENDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=MflmPHSENDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.HARVESTER: { DataSourceKey.PHSEN_ABCDEF_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, DataSourceKey.PHSEN_ABCDEF: { DataSetDriverConfigKeys.DIRECTORY: RECOVERED_DIR, DataSetDriverConfigKeys.PATTERN: 'SAMI_*.txt', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, } }, DataSourceConfigKey.PARSER: { DataSourceKey.PHSEN_ABCDEF_SIO_MULE: {}, DataSourceKey.PHSEN_ABCDEF: {} } }) ###############################################################################
from mi.dataset.parser.ctdmo import CtdmoParserDataParticle, DataParticleType from mi.dataset.parser.ctdmo import CtdmoOffsetDataParticle TELEM_DIR = '/tmp/dsatest' DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.ctd.driver', driver_class="MflmCTDMODataSetDriver", agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmCTDMODataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataSourceKey.CTDMO_GHQR_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, } }, DataSourceConfigKey.PARSER: { DataSourceKey.CTDMO_GHQR_SIO_MULE: {'inductive_id': 55} } } ) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for #
SIO_ENG_PATTERN = 'STA*.DAT' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.sio_eng.sio_mule.driver', driver_class='SioEngSioMuleDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=SioEngSioMuleDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.HARVESTER: { DataSourceKey.SIO_ENG_SIO_MULE_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: MULE_FILE_NAME, DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, DataSourceKey.SIO_ENG_SIO_MULE_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: SIO_ENG_PATTERN, DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, } }, DataSourceConfigKey.PARSER: { DataSourceKey.SIO_ENG_SIO_MULE_TELEMETERED: {}, DataSourceKey.SIO_ENG_SIO_MULE_RECOVERED: {} } }) ############################################################################### # INTEGRATION TESTS #
from mi.dataset.parser.wfp_eng__stc_imodem import DataParticleType, Wfp_eng__stc_imodem_statusParserDataParticle from mi.dataset.parser.wfp_eng__stc_imodem import Wfp_eng__stc_imodem_startParserDataParticle from mi.dataset.parser.wfp_eng__stc_imodem import Wfp_eng__stc_imodem_engineeringParserDataParticle from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.WFP_ENG.STC_IMODEM.driver', driver_class='WFP_ENG__STC_IMODEM_DataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = WFP_ENG__STC_IMODEM_DataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'wfp_eng__stc_imodem', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ############################################################################### @attr('INT', group='mi')
RECOV_DIR = '/tmp/dsatest2' DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.flort.driver', driver_class='MflmFLORTDDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmFLORTDDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataSourceKey.FLORT_DJ_SIO_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, DataSourceKey.FLORT_DJ_SIO_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: 'FLO*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 2, }, }, DataSourceConfigKey.PARSER: { DataSourceKey.FLORT_DJ_SIO_TELEMETERED: {}, DataSourceKey.FLORT_DJ_SIO_RECOVERED: {} } } ) ###############################################################################
from interface.objects import ResourceAgentErrorEvent from mi.dataset.driver.RTE.STC.driver import RteOStcDataSetDriver from mi.dataset.parser.rte_o_stc import RteOStcParserDataParticle # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.RTE.STC.driver', driver_class='RteOStcDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = RteOStcDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'rte_o_stc', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: '*.rte.log', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) SAMPLE_STREAM = 'rte_xx__stc_instrument' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities #
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.dosta_abcdjm.dcl.driver', driver_class='DostaAbcdjmDclDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = DostaAbcdjmDclDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.HARVESTER: { DataTypeKey.DOSTA_ABCDJM_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: REC_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.dosta*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, DataTypeKey.DOSTA_ABCDJM_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TEL_DIR, DataSetDriverConfigKeys.PATTERN: '[0-9]*.dosta*.log', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 30, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.DOSTA_ABCDJM_RECOVERED: {}, DataTypeKey.DOSTA_ABCDJM_TELEMETERED: {} } } )
FILE_TEL = 'node58p1.dat' # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.vel3d_l.wfp.driver', driver_class='Vel3dLWfp', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=Vel3dLWfp.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'vel3d_l_wfp', DataSourceConfigKey.HARVESTER: { DataTypeKey.VEL3D_L_WFP: { DataSetDriverConfigKeys.DIRECTORY: DIR_REC, DataSetDriverConfigKeys.PATTERN: 'A*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.VEL3D_L_WFP_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: DIR_TEL, DataSetDriverConfigKeys.PATTERN: FILE_TEL, DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.VEL3D_L_WFP: {}, DataTypeKey.VEL3D_L_WFP_SIO_MULE: {} } }) PARSER_STATE = 'parser_state'
RECOVERED_SAMPLE_DATA = 'E0000001.DAT' DataSetTestCase.initialize( driver_module='mi.dataset.driver.flord_l_wfp.sio_mule.driver', driver_class='FlordLWfpSioMuleDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=FlordLWfpSioMuleDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'flord_l_wfp_sio_mule', DataSourceConfigKey.HARVESTER: { DataSourceKey.FLORD_L_WFP_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'TestData.dat', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceKey.FLORD_L_WFP: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DIR, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataSourceKey.FLORD_L_WFP_SIO_MULE: {}, DataSourceKey.FLORD_L_WFP: {} } }) SAMPLE_STREAM = 'flord_l_wfp_instrument'
from interface.objects import ResourceAgentErrorEvent from interface.objects import ResourceAgentConnectionLostErrorEvent DATADIR = "/tmp/dsatest" STORAGEDIR = "/tmp/stored_dsatest" RESOURCE_ID = "ctdgv" DataSetTestCase.initialize( driver_module="mi.dataset.driver.moas.gl.ctdgv.driver", driver_class="CTDGVDataSetDriver", agent_resource_id="123xyz", agent_name="Agent007", agent_packet_config=CTDGVDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: RESOURCE_ID, DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: DATADIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: STORAGEDIR, DataSetDriverConfigKeys.PATTERN: "*.mrg", DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {}, }, ) SAMPLE_STREAM = "ggldr_ctdgv_delayed" ############################################################################### # UNIT TESTS # # Device specific unit tests are for # # testing device specific capabilities #
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.WFP_ENG.wfp.driver', driver_class='WfpEngWfp', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=WfpEngWfp.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'wfp_eng_wfp', DataSourceConfigKey.HARVESTER: { DataTypeKey.WFP_ENG_STC_IMODEM: { DataSetDriverConfigKeys.DIRECTORY: DIR_REC, DataSetDriverConfigKeys.PATTERN: 'E*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.WFP_ENG_WFP_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: DIR_TEL, DataSetDriverConfigKeys.PATTERN: FILE_TEL, DataSetDriverConfigKeys.FREQUENCY: 1, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.WFP_ENG_STC_IMODEM: {}, DataTypeKey.WFP_ENG_WFP_SIO_MULE: {}, } } )
# Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.adcps_jln.stc.driver', driver_class='AdcpsJlnStcDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=AdcpsJlnStcDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'adcps_jln_stc', DataSourceConfigKey.HARVESTER: { DataTypeKey.ADCPS_JLN_STC: { DataSetDriverConfigKeys.DIRECTORY: ADCPS_JLN_TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'adcp[st]_*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.ADCPS_JLN: { DataSetDriverConfigKeys.DIRECTORY: ADCPS_JLN_RECOVERED_DIR, DataSetDriverConfigKeys.PATTERN: '*.PD0', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.ADCPS_JLN_STC: {}, DataTypeKey.ADCPS_JLN: {} } } )
from mi.dataset.dataset_driver import DriverParameter from pyon.agent.agent import ResourceAgentState from interface.objects import ResourceAgentErrorEvent from mi.dataset.driver.issmcnsm.dosta.driver import IssmCnsmDOSTADDataSetDriver from mi.dataset.parser.issmcnsm_dostad import Issmcnsm_dostadParserDataParticle # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.issmcnsm.dosta.driver', driver_class='IssmCnsmDOSTADDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = IssmCnsmDOSTADDataSetDriver.stream_config(), startup_config = { 'harvester': { 'directory': '/tmp/dsatest', 'pattern': '*.dosta.log', 'frequency': 1, }, 'parser': {} } ) SAMPLE_STREAM = 'issmcnsm_dostad_parsed' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ###############################################################################
from mi.dataset.dataset_driver import DriverParameter from mi.dataset.dataset_driver import DataSourceConfigKey, DataSetDriverConfigKeys from mi.dataset.driver.adcps_jln.stc.driver import AdcpsJlnStcDataSetDriver from mi.dataset.parser.adcps_jln_stc import AdcpsJlnStcInstrumentParserDataParticle, DataParticleType from mi.dataset.parser.adcps_jln_stc import AdcpsJlnStcMetadataParserDataParticle # Fill in driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.adcps_jln.stc.driver', driver_class='AdcpsJlnStcDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = AdcpsJlnStcDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'adcps_jln_stc', DataSourceConfigKey.HARVESTER: { DataSetDriverConfigKeys.DIRECTORY: '/tmp/dsatest', DataSetDriverConfigKeys.PATTERN: 'adcp[st]_*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataSourceConfigKey.PARSER: {} } ) ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for # # testing device specific capabilities # ############################################################################### @attr('INT', group='mi')
DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.dosta.driver', driver_class="DOSTADataSetDriver", agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=DOSTADataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'dosta', DataSourceConfigKey.HARVESTER: { DataTypeKey.DOSTA_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEMETERED_TEST_DIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dostaTelemeteredTest', DataSetDriverConfigKeys.PATTERN: '*.mrg', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.DOSTA_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOVERED_TEST_DIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dostaRecoveredTest', DataSetDriverConfigKeys.PATTERN: '*.mrg', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.DOSTA_TELEMETERED: {}, DataTypeKey.DOSTA_RECOVERED: {} } })
from mi.dataset.driver.mflm.adcp.driver import MflmADCPSDataSetDriver, DataSourceKey from mi.dataset.parser.adcps import AdcpsParserDataParticle TELEM_DIR = '/tmp/dsatest' # Fill in the blanks to initialize data set test case DataSetTestCase.initialize( driver_module='mi.dataset.driver.mflm.adcp.driver', driver_class='MflmADCPSDataSetDriver', agent_resource_id = '123xyz', agent_name = 'Agent007', agent_packet_config = MflmADCPSDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'adcps', DataSourceConfigKey.HARVESTER: { DataSourceKey.ADCPS_JLN_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: TELEM_DIR, DataSetDriverConfigKeys.PATTERN: 'node59p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, DataSetDriverConfigKeys.FILE_MOD_WAIT_TIME: 5 } }, DataSourceConfigKey.PARSER: { DataSourceKey.ADCPS_JLN_SIO_MULE: {} } } ) SAMPLE_STREAM='adcps_jln_sio_mule_instrument' ############################################################################### # INTEGRATION TESTS # # Device specific integration tests are for #
# Driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.ctdpf_ckl.wfp_sio_mule.driver', driver_class='CtdpfCklWfpDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=CtdpfCklWfpDataSetDriver.stream_config(), startup_config = { DataSourceConfigKey.RESOURCE_ID: 'ctdpf_ckl_wfp_sio_mule', DataSourceConfigKey.HARVESTER: { DataTypeKey.CTDPF_CKL_WFP: { DataSetDriverConfigKeys.DIRECTORY: RECOV_DATA_DIR, DataSetDriverConfigKeys.PATTERN: 'C*.DAT', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.CTDPF_CKL_WFP_SIO_MULE: { DataSetDriverConfigKeys.DIRECTORY: MULE_DATA_DIR, DataSetDriverConfigKeys.PATTERN: 'node58p1.dat', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.CTDPF_CKL_WFP: {}, DataTypeKey.CTDPF_CKL_WFP_SIO_MULE: {} } } )
PARAD_TEL_PATTERN = '*PPD_PARS.txt' # Driver details DataSetTestCase.initialize( driver_module='mi.dataset.driver.parad_j.cspp.driver', driver_class='ParadJCsppDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=ParadJCsppDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'parad_j_cspp', DataSourceConfigKey.HARVESTER: { DataTypeKey.PARAD_J_CSPP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_PARAD_TELEMETERED, DataSetDriverConfigKeys.PATTERN: PARAD_TEL_PATTERN, DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.PARAD_J_CSPP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_PARAD_RECOVERED, DataSetDriverConfigKeys.PATTERN: PARAD_REC_PATTERN, DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.PARAD_J_CSPP_TELEMETERED: {}, DataTypeKey.PARAD_J_CSPP_RECOVERED: {} } }) REC_PARTICLES = (ParadJCsppMetadataRecoveredDataParticle, ParadJCsppInstrumentRecoveredDataParticle)
DataSetTestCase.initialize( driver_module='mi.dataset.driver.moas.gl.dosta.driver', driver_class="DOSTADataSetDriver", agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=DOSTADataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'dosta', DataSourceConfigKey.HARVESTER: { DataTypeKey.DOSTA_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: TELEMETERED_TEST_DIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dostaTelemeteredTest', DataSetDriverConfigKeys.PATTERN: '*.mrg', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.DOSTA_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: RECOVERED_TEST_DIR, DataSetDriverConfigKeys.STORAGE_DIRECTORY: '/tmp/stored_dostaRecoveredTest', DataSetDriverConfigKeys.PATTERN: '*.mrg', DataSetDriverConfigKeys.FREQUENCY: 1, } }, DataSourceConfigKey.PARSER: { DataTypeKey.DOSTA_TELEMETERED: {}, DataTypeKey.DOSTA_RECOVERED: {} } } )
DIR_REC = '/tmp/dsatest_rec' DIR_TEL = '/tmp/dsatest_tel' DataSetTestCase.initialize( driver_module='mi.dataset.driver.dosta_abcdjm.cspp.driver', driver_class='DostaAbcdjmCsppDataSetDriver', agent_resource_id='123xyz', agent_name='Agent007', agent_packet_config=DostaAbcdjmCsppDataSetDriver.stream_config(), startup_config={ DataSourceConfigKey.RESOURCE_ID: 'dosta_abcdjm_cspp', DataSourceConfigKey.HARVESTER: { DataTypeKey.DOSTA_ABCDJM_CSPP_RECOVERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_REC, DataSetDriverConfigKeys.PATTERN: '*_PPB_OPT.txt', DataSetDriverConfigKeys.FREQUENCY: 1, }, DataTypeKey.DOSTA_ABCDJM_CSPP_TELEMETERED: { DataSetDriverConfigKeys.DIRECTORY: DIR_TEL, DataSetDriverConfigKeys.PATTERN: '*_PPD_OPT.txt', DataSetDriverConfigKeys.FREQUENCY: 1, }, }, DataSourceConfigKey.PARSER: { DataTypeKey.DOSTA_ABCDJM_CSPP_RECOVERED: {}, DataTypeKey.DOSTA_ABCDJM_CSPP_TELEMETERED: {}, } }) REC_PARTICLES = (DostaAbcdjmCsppMetadataRecoveredDataParticle, DostaAbcdjmCsppInstrumentRecoveredDataParticle)