module CassandraCleaner::CqlRspecNotifications::Client

Public Instance Methods

execute_with_notify(*args) click to toggle source
# File lib/cassandra_cleaner/cql_rspec_notifications.rb, line 22
def execute_with_notify(*args)
  res = execute_without_notify(*args)
  table_name = grap_table_name(args)
  notify_observers(table_name)
  res
end
grap_table_name(args) click to toggle source
# File lib/cassandra_cleaner/cql_rspec_notifications.rb, line 29
def grap_table_name(args)
  $1.split('.').last if args && args.first.match(/(?:INSERT INTO|UPDATE)\s([\w\.]*)\s.*/)        
end