def test_first_location_of_maximum(self):
        self.assertAlmostEqualOnAllArrayTypes(
            first_location_of_maximum, [1, 2, 1, 2, 1], 0.2
        )
        self.assertAlmostEqualOnAllArrayTypes(
            first_location_of_maximum, [1, 2, 1, 1, 2], 0.2
        )
        self.assertAlmostEqualOnAllArrayTypes(
            first_location_of_maximum, [2, 1, 1, 1, 1], 0.0
        )
        self.assertAlmostEqualOnAllArrayTypes(
            first_location_of_maximum, [1, 1, 1, 1, 1], 0.0
        )
        self.assertAlmostEqualOnAllArrayTypes(first_location_of_maximum, [1], 0.0)
        self.assertIsNanOnAllArrayTypes(first_location_of_maximum, [])