def test_lastndays(self):
        params = process_url_params({'date-lastndays': '30'}, self.columns)
        result_filter = params.sql_filters[0]

        end = datetime.date.today()
        start = end - datetime.timedelta(days=30)
        date_column = self.columns['date']
        desired_filter = date_column.between(start, end)

        self.assertTrue(result_filter.compare(desired_filter))
dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/userreports/tests/test_export.py/ParameterTest.test_lastndays/original