from __future__ import unicode_literals

import unittest

import nose

from ldclient.__experimental.experimental_models import (
    QueryCondition,)


class ExperimentalLDModelsUnitTests(unittest.TestCase):

    maxDiff = None

    def testQueryCondition(self):
        query_condition_def = {
            'type': 'observation',
            'id': '1',
            'value': 'abc',
            'value_type': 'value',
            'addable_column_id': '113',
        }
        query_condition_obj = QueryCondition.from_dict(query_condition_def)
        self.assertDictEqual(query_condition_def, query_condition_obj.as_dict())


if __name__ == "__main__":
    nose.run(argv=["", "experimental_ldclient_unit_tests", "-s", "--verbosity=2"])
