'Test for inserting all column types into a UserType
test_can_insert_udts_with_all_datatypes tests that each cqlengine column type can be inserted into a UserType.
It first creates a UserType that has each cqlengine column type, and a corresponding table/Model. It then creates
a UserType instance where all the fields have corresponding data, and inserts the UserType as an instance of the Model.
Finally, it verifies that each column read from the UserType from Cassandra is the same as the input parameters.
@since 2.5.0
@jira_ticket PYTHON-251
@expected_result The UserType is inserted with each column type, and the resulting read yields proper data for each column.
@test_category data_types:udt'

def test_can_insert_udts_with_all_datatypes(self):

    sync_table(AllDatatypesModel)
    self.addCleanup(drop_table, AllDatatypesModel)
    input = AllDatatypes(a='ascii', b=((2 ** 63) - 1), c=bytearray('hello    world'), d=True, e=datetime.utcfromtimestamp(872835240), f=Decimal('12.3E+7'), g=2.39, h=3.4028234663852886e+38, i='123.123.123.123', j=2147483647, k='text', l=UUID('FE2B4360-28C6-11E2-81C1-0800200C9A66'), m=UUID('067e6162-3b6f-4ae2-a171-2470b63dff00'), n=int((str(2147483647) + '000')))
    AllDatatypesModel.create(id=0, data=input)
    self.assertEqual(1, AllDatatypesModel.objects.count())
    output = AllDatatypesModel.objects.first().data
    for i in range(ord('a'), (ord('a') + 14)):
        self.assertEqual(input[chr(i)], output[chr(i)])
