Philip Thompson created CASSANDRA-10932:
-------------------------------------------
Summary: pushed_notifications_test.py schema_changes_test is
failing
Key: CASSANDRA-10932
URL: https://issues.apache.org/jira/browse/CASSANDRA-10932
Project: Cassandra
Issue Type: Sub-task
Reporter: Philip Thompson
Fix For: 3.0.x, 3.x
{{pushed_notifications_test.py:TestPushedNotifications.schema_changes_test}} is
failing on HEAD of cassandra-3.0. It may be simply a problem with the test
assertions, so someone just needs to double check if the schema change
notifications pushed to the driver are correct.
In actuality, the driver gets 8 notifications, listed in the debug output of
the test failure:
{code}
======================================================================
FAIL: schema_changes_test (pushed_notifications_test.TestPushedNotifications)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/philipthompson/cstar/cassandra-dtest/tools.py", line 253, in
wrapped
f(obj)
File
"/Users/philipthompson/cstar/cassandra-dtest/pushed_notifications_test.py",
line 244, in schema_changes_test
self.assertEquals(14, len(notifications))
AssertionError: 14 != 8
-------------------- >> begin captured logging << --------------------
dtest: DEBUG: cluster ccm directory:
/var/folders/v3/z4wf_34n1q506_xjdy49gb780000gn/T/dtest-93xMe2
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'CREATED', 'target_type': uCorrect typo in MV creation query
'KEYSPACE'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'CREATED', 'target_type': u'TABLE', u'table': u't'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'UPDATED', 'target_type': u'TABLE', u'table': u't'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'CREATED', 'target_type': u'TABLE', u'table': u'mv'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'UPDATED', 'target_type': u'TABLE', u'table': u'mv'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'DROPPED', 'target_type': u'TABLE', u'table': u'mv'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'DROPPED', 'target_type': u'TABLE', u'table': u't'}
dtest: DEBUG: Source 127.0.0.2 sent {'keyspace': u'ks', 'change_type':
u'DROPPED', 'target_type': u'KEYSPACE'}
dtest: DEBUG: Waiting for notifications from 127.0.0.2
--------------------- >> end captured logging << ---------------------
{code}
The test has been expecting the following 14, though:
{code}
self.assertDictContainsSubset({'change_type': u'CREATED', 'target_type':
u'KEYSPACE'}, notifications[0])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[1])
self.assertDictContainsSubset({'change_type': u'CREATED',
'target_type': u'TABLE', u'table': u't'}, notifications[2])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[3])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'TABLE', u'table': u't'}, notifications[4])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[5])
self.assertDictContainsSubset({'change_type': u'CREATED',
'target_type': u'TABLE', u'table': u'mv'}, notifications[6])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[7])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'TABLE', u'table': u'mv'}, notifications[8])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[9])
self.assertDictContainsSubset({'change_type': u'DROPPED',
'target_type': u'TABLE', u'table': u'mv'}, notifications[10])
self.assertDictContainsSubset({'change_type': u'UPDATED',
'target_type': u'KEYSPACE'}, notifications[11])
self.assertDictContainsSubset({'change_type': u'DROPPED',
'target_type': u'TABLE', u'table': u't'}, notifications[12])
self.assertDictContainsSubset({'change_type': u'DROPPED',
'target_type': u'KEYSPACE'}, notifications[13])
{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)