def preset_season_factor_test(self):
        """Initial Season Factors should be presetable"""
        hwm = HoltWintersMethod(seasonLength=4)
        factors = [0,1,2,3]
        hwm.set_parameter("seasonValues", factors)

        data = [[0, 362.0], [1,385.0], [2, 432.0], [3, 341.0], [4, 382.0], [5, 409.0], [6, 498.0], [7, 387.0], [8, 473.0], [9, 513.0], [10, 582.0], [11, 474.0]]
        tsSrc = TimeSeries.from_twodim_list(data)
        seasonValues = hwm.initSeasonFactors(tsSrc)

        assert seasonValues == factors, "Preset Season Factors are not returned by initSeasonFactors"

        hwm.set_parameter("seasonValues", factors[:2])
        try:
            hwm.initSeasonFactors(tsSrc)
        except __HOLE__:
            pass
        else:
            assert False, "If preset season factors and season length do not comply, initSeasonFactors should throw an AssertionError"    # pragma: no cover
dataset/ETHPy150Open T-002/pycast/pycast/tests/methodtest.py/HoltWintersMethodTest.preset_season_factor_test