Use numpys array_equal function in tests
When having tests that produces nan-values as a valid result we want to be able to test this. As it is right now comparing two nan-values will result in not equal. To be able of comparing nan-values we can switch to using numpy function array_equal and set input parameter equal_nan = True. This function also compares shapes of the result and the data values underneath masked values. Switching to the array_equal function generates some errors in the tests listed bellow:
-
FirstOccurrence and LastOccurrence, call/lazy function last test generates an error due to inaccurate shape of expected output. (Error in test parameters) -
Percentile and ThresholdedPercentile, call function all tests returns an inaccurate shape of result. (Error in call function) -
ThresholdedRunningStatistics, call/lazy function tests 2 and 4 returns an error due to wrong data value underneath the mask in the expected output. (Error in test parameters)