#312 Change subjectType from airQualityControl to airQualitySensor #487
#312 Change subjectType from airQualityControl to airQualitySensor #487ShreejeetaMandal wants to merge 1 commit intoConnectedPlacesCatapult:masterfrom
Conversation
… to airQualitySensor and change datasourceId form airQualityControl to airQuality
lorenaqendro
left a comment
There was a problem hiding this comment.
Hi @ShreejeetaMandal, thank you for taking care of this issue. I have left you two comments you can have a look at and make the changes needed.
Also, the issue mentioned a couple of other points:
- Change package name from lac to laqn
- Change provider from erg.kcl.ac.uk to uk.ac.kcl.erg
Do you wish to add them here or on another PR? I cannot close the issue until they're done ;)
Please, tag me when you address the comments so I can approve the changes.
| private static final String LAQN_PROVIDER_LABEL = "erg.kcl.ac.uk"; | ||
| private static final String LAQN_PROVIDER_NAME = "Environmental Research Group Kings College London"; | ||
| private static final String LAQN_SUBJECT_TYPE_LABEL = "airQualityControl"; | ||
| private static final String LAQN_SUBJECT_TYPE_LABEL = "airQualitySensor"; |
There was a problem hiding this comment.
This importer is missing a proper datasourceId and is using the subject type label for it, this is why in the tests you had to insert the subject type instead. My suggestion is to add another static variable here and use it in line 45.
private static final String DATASOURCE_ID = "airQuality"; and in line 45
datasourceSpec = new DatasourceSpec(getClass(), DATASOURCE_ID, "Air Quality London",
"Data captured by sensors operated by London Air", dataSourceURL);
Now you can use the datasourceId airQuality in the tests and the recipes will run.
| @Test | ||
| public void testGetProvider() throws Exception { | ||
| laqnImporter.importDatasource("airQualityControl", | ||
| laqnImporter.importDatasource("airQualitySensor", |
There was a problem hiding this comment.
As mentioned in the first the comment on the top, now you can have "airQuality" here and in the other importDatascource() methods in the test.
lorenaqendro
left a comment
There was a problem hiding this comment.
Please, have a look at the comments and address them.
Description
Checklist