#NEWLINE# def test_from_csv( testcase , filename , filterClassBuilder , roundDecimals = 2 , maxLen = None ) : #NEWLINE# #INDENT# ( inputValues , expectedValues ) = load_test_csv ( get_data_file_path ( filename ) ) #NEWLINE# inputDS = dataseries . SequenceDataSeries ( maxLen = expectedValues ) #NEWLINE# filterDS = filterClassBuilder ( inputDS ) #NEWLINE# for i in xrange ( len ( inputValues ) ) : #NEWLINE# #INDENT# inputDS . append ( inputValues [ i ] ) #NEWLINE# value = safe_round ( filterDS [ i ] , roundDecimals ) #NEWLINE# expectedValue = safe_round ( expectedValues [ i ] , roundDecimals ) #NEWLINE# testcase . assertEqual ( value , expectedValue )