Module: DbAgile::Contract::Robust::Optimistic::Data::TableDriven

Included in:
DbAgile::Contract::Robust::Optimistic
Defined in:
lib/dbagile/contract/robust/optimistic/data/table_driven.rb

Instance Method Summary collapse

Instance Method Details

#dataset(*args, &block) ⇒ Object



9
10
11
12
13
14
15
16
# File 'lib/dbagile/contract/robust/optimistic/data/table_driven.rb', line 9

def dataset(*args, &block)
  ds = delegate.dataset(*args, &block)
  ds.empty?
  ds
rescue StandardError => ex
  has_table!(args[0], ex)
  raise
end

#exists?(*args, &block) ⇒ Boolean

Returns:

  • (Boolean)

See Also:



19
20
21
22
23
24
# File 'lib/dbagile/contract/robust/optimistic/data/table_driven.rb', line 19

def exists?(*args, &block)
  delegate.exists?(*args, &block)
rescue StandardError => ex
  has_table!(args[0], ex)
  raise
end