def test_date_freqquencies(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["frequencies"] == [('2008-12-20T00:00:00Z', 2), ('2010-12-23T00:00:00Z', 1), ('2000-12-22T00:00:00Z', 1)]
def test_date_freqquencies(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["frequencies"] == [ ("2008-12-20T00:00:00Z", 2), ("2010-12-23T00:00:00Z", 1), ("2000-12-22T00:00:00Z", 1), ]
def test_date_unique_count(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["unique_count"] == 3
def test_date_median(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["median"] == "2008-12-20T00:00:00Z"
def test_date_min(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["min"] == "2000-12-22T00:00:00Z"
def test_date_max(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["max"] == "2010-12-23T00:00:00Z"
def test_date_invalid_count(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["invalid"] == 0
def test_date_mode_count(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["mode_frequency"] == 2
def test_date_mode(): test_series = date_series print test_series[0].isoformat() test_analysis = analyze.dateAnalysis(test_series) assert test_analysis["mode"] == ['2008-12-20T00:00:00Z']