Ekaterina Dimitrova created CASSANDRA-19173:
-----------------------------------------------

             Summary: Test Failure: 
dtest-novnode.cqlsh_tests.test_cqlsh_copy.TestCqlshCopy.test_round_trip_with_sub_second_precision
                 Key: CASSANDRA-19173
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-19173
             Project: Cassandra
          Issue Type: Bug
            Reporter: Ekaterina Dimitrova


{quote}
h3. Error Message
AssertionError: assert [['1', '1943-06-19 11:21:01.000+0000'], ['2', 
'1943-06-19 11:21:01.123+0000'], ['3', '1943-06-19 11:21:01.124+0000']] == 
[['3', '1943-06-19 11:21:01.124+0000']] At index 0 diff: ['1', '1943-06-19 
11:21:01.000+0000'] != ['3', '1943-06-19 11:21:01.124+0000'] Left contains 2 
more items, first extra item: ['2', '1943-06-19 11:21:01.123+0000'] Full diff: 
[ + ['1', + '1943-06-19 11:21:01.000+0000'], + ['2', + '1943-06-19 
11:21:01.123+0000'], ['3', '1943-06-19 11:21:01.124+0000'], ]
h3. Stacktrace
self = <cqlsh_tests.test_cqlsh_copy.TestCqlshCopy object at 0x7ff2be7c4110> 
@since('3.4') def test_round_trip_with_sub_second_precision(self): """ Test 
that we can import and export timestamp values with millisecond precision: - 
create a csv file and import it - export the data and check the values are as 
expected @jira_ticket CASSANDRA-10428 """ self.prepare() 
self.session.execute("create TABLE testsubsecond(id int PRIMARY KEY, subid 
timestamp)") tempfile1 = self.get_temp_file() tempfile2 = self.get_temp_file() 
with open(tempfile1.name, 'w') as csvfile: writer = csv.writer(csvfile) 
writer.writerow([1, '1943-06-19 11:21:01+0000']) writer.writerow([2, 
'1943-06-19 11:21:01.123+0000']) writer.writerow([3, '1943-06-19 
11:21:01.123456+0000']) logger.debug('Importing from csv file: 
{}'.format(tempfile1.name)) self.run_cqlsh(cmds="COPY ks.testsubsecond FROM 
'{}'".format(tempfile1.name)) logger.debug('Exporting to csv file: 
{}'.format(tempfile2.name)) self.run_cqlsh(cmds="COPY ks.testsubsecond TO 
'{}'".format(tempfile2.name)) csv_results = 
sorted(list(csv_rows(tempfile2.name))) > assert [['1', '1943-06-19 
11:21:01.000+0000'], ['2', '1943-06-19 11:21:01.123+0000'], ['3', '1943-06-19 
11:21:01.124+0000']] == csv_results E AssertionError: assert [['1', '1943-06-19 
11:21:01.000+0000'], ['2', '1943-06-19 11:21:01.123+0000'], ['3', '1943-06-19 
11:21:01.124+0000']] == [['3', '1943-06-19 11:21:01.124+0000']] E At index 0 
diff: ['1', '1943-06-19 11:21:01.000+0000'] != ['3', '1943-06-19 
11:21:01.124+0000'] E Left contains 2 more items, first extra item: ['2', 
'1943-06-19 11:21:01.123+0000'] E Full diff: E [ E + ['1', E + '1943-06-19 
11:21:01.000+0000'], E + ['2', E + '1943-06-19 11:21:01.123+0000'], E ['3', E 
'1943-06-19 11:21:01.124+0000'], E ] cqlsh_tests/test_cqlsh_copy.py:2005: 
AssertionError{quote}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to