Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

One more error check.

  • Loading branch information...
commit 675ec688a6edb56d3a2a5a1e12b43b496094cf85 1 parent 176c706
@JEG2 authored
Showing with 7 additions and 0 deletions.
  1. +7 −0 test/tc_update.rb
View
7 test/tc_update.rb
@@ -32,6 +32,13 @@ def test_fields_are_retyped_on_claim
assert_match(/\ACOUNTER:/, @db.fields(true)["b"])
end
+ def test_bad_schema_for_update_raises_tune_error
+ RRDB.config(:reserve_fields => 2)
+ @db.update(Time.now, :a => 1)
+ RRDB.config(:data_sources => {:b => "BAD_FIELD_TYPE"})
+ assert_raise(RRDB::TuneError) { @db.update(Time.now + 10, :b => 2) }
+ end
+
def test_running_out_of_fields_to_claim_raises_fields_exhausted_error
RRDB.config(:reserve_fields => 3)
test_update_claims_new_fields_as_needed
Please sign in to comment.
Something went wrong with that request. Please try again.