

def test_dictionary_both_keys(self):
    import datetime
    from gcloud.bigtable.column_family import GCRuleIntersection
    from gcloud.bigtable.column_family import MaxAgeGCRule
    from gcloud.bigtable.column_family import MaxVersionsGCRule
    versions = 42
    time_to_live = ((24 * 60) * 60)
    option = {
        'max_versions': versions,
        'time_to_live': time_to_live,
    }
    result = self._callFUT(option)
    max_age = datetime.timedelta(days=1)
    gc_rule1 = MaxAgeGCRule(max_age)
    gc_rule2 = MaxVersionsGCRule(versions)
    gc_rule = GCRuleIntersection(rules=[gc_rule1, gc_rule2])
    self.assertEqual(result, gc_rule)

dataset/ETHPy150Open GoogleCloudPlatform/gcloud-python/gcloud/bigtable/happybase/test_connection.py Test__parse_family_option.test_dictionary_both_keys/original