def test_granulairty_positive(): from adobe_analytics.reports.report_definition import ReportDefinition definition = ReportDefinition(metrics="pageviews", dimensions="page", last_days=7, granularity="week") definition._validate_granularity()
def test_granulairty_negative(): from adobe_analytics.reports.report_definition import ReportDefinition definition = ReportDefinition(metrics="pageviews", dimensions="page", last_days=7, granularity="days") with pytest.raises(AssertionError): definition._validate_granularity()