Exemple #1
0
    def test_considered_shores_geo(self):
        self.config.annotations.geo = "shores"
        annotations_dict1 = {AnnotationKey.geo.value: "N_Shore"}
        annotations_dict2 = {AnnotationKey.geo.value: "S_Shore"}

        condition1 = geo_condition(self.config, annotations_dict1)
        condition2 = geo_condition(self.config, annotations_dict2)

        self.assertEqual(True, condition1 and condition2)
Exemple #2
0
    def test_considered_any_geo(self):
        annotations_dict1 = {AnnotationKey.geo.value: "N_Shore"}
        annotations_dict2 = {AnnotationKey.geo.value: "S_Shore"}
        annotations_dict3 = {AnnotationKey.geo.value: "Island"}
        annotations_dict4 = {AnnotationKey.geo.value: "S_Shelf"}

        condition1 = geo_condition(self.config, annotations_dict1)
        condition2 = geo_condition(self.config, annotations_dict2)
        condition3 = geo_condition(self.config, annotations_dict3)
        condition4 = geo_condition(self.config, annotations_dict4)

        self.assertEqual(
            True, condition1 and condition2 and condition3 and condition4)
Exemple #3
0
    def test_exclude_n_shore_for_s_shore_geo(self):
        self.config.annotations.geo = "S_Shore"
        annotations_dict = {AnnotationKey.geo.value: "N_Shore"}

        condition = geo_condition(self.config, annotations_dict)

        self.assertEqual(False, condition)
Exemple #4
0
    def test_exclude_islands_shores_for_shore_geo(self):
        self.config.annotations.geo = "shores"
        annotations_dict = {AnnotationKey.geo.value: "Island"}

        condition = geo_condition(self.config, annotations_dict)

        self.assertEqual(False, condition)
Exemple #5
0
    def test_considered_islands_shores_geo(self):
        self.config.annotations.geo = "islands_shores"
        annotations_dict = {AnnotationKey.geo.value: "Island"}

        condition = geo_condition(self.config, annotations_dict)

        self.assertEqual(True, condition)
Exemple #6
0
    def test_considered_shores_n_geo(self):
        self.config.annotations.geo = "shores_n"
        annotations_dict = {AnnotationKey.geo.value: "N_Shore"}

        condition = geo_condition(self.config, annotations_dict)

        self.assertEqual(True, condition)