Skip to content

Fix a bug with DataQualityFlag subtraction & revise a few tests

Created by: asouthgate

This fixes a bug in DataQualityFlag subtraction (https://github.com/gwpy/gwpy/issues/1700) documentation and improves the test for it.

This also changes a few other test assertions in DataQualityDict which I believe were not testing correct elements.

E.g.

    def __isub__(self, other):
        for key, value in other.items():
            if key in self:
                self[key] -= value
        return self

Subtraction is based on keys. However, the tests were testing on order, which was not the same thing.

Merge request reports

Loading