Class: ScraperWiki::API::Matchers::ExtraKeysMatcher
Instance Method Summary
collapse
Instance Method Details
#difference ⇒ Object
316
317
318
319
320
321
322
323
|
# File 'lib/scraperwiki-api/matchers.rb', line 316
def difference
keys = if @actual['datasummary']['tables'][@table]
@actual['datasummary']['tables'][@table]['keys']
else
[]
end
keys - @expected
end
|
#failure_predicate ⇒ Object
325
326
327
|
# File 'lib/scraperwiki-api/matchers.rb', line 325
def failure_predicate
'has extra keys'
end
|
#negative_failure_predicate ⇒ Object
329
330
331
|
# File 'lib/scraperwiki-api/matchers.rb', line 329
def negative_failure_predicate
'has no extra keys'
end
|