Use ternary operator for brevity
Fix indentation and unused variable warnings
Replace `setup` and `teardown` with `around` and a block.
Use transaction in `around` method
Remove insert from around block

Only one test depends on this record having been inserted, so insert it
in the test rather than during suite setup
Always use AR::Base.table_name=

Since we now only support Active Record 3.2 or higher, we can assume
this method in all model classes.
Move some test model class setup to around block
Use Number in place of TestClass in most tests

We're clearing the Number before and after each test, so we can safely
use it directly in our tests now, which makes the code easier to read
and write.
Use "book" in place of "number"

`Book#number` looks less silly than `Number#number`
Remove "define_model_class" from test

Use the real model classes instead.
Avoid unnecessary use of global variable
Make test code more concise by avoiding unecessary assignment
Spacing
Handle AR 3 version and feature setup more precisely

AR < 4 now always means >= 3.2.0, and we can always assume the
:without_protection option is supported.
Rename test for clarity
Update comments
Use appraisal gem to manage gemfiles
Move AR 3 specs to bottom. Assume AR < 4 == 3 as per gemspec.
Fix setting defaults for nested attributes

Resolves #16
Invoke ActiveSupport::Dependencies.clear after test runs

On Rails 4.1+, depending on the order the tests run in, the Book class
created during test setup will sometimes be resolved to the same class
used by a previous test method, even though the constant it was assigned
to has been unset. This is because the class is still assigned
anonymously as the value to the "Book" key in an instance of
ActiveSupport::Dependencies::ClassCache.

You can see this symptom by checking out the previous commit and
running:

  BUNDLE_GEMFILE=gemfiles/Rails_42.gemfile bundle exec ruby  -e 'require "./test.rb"' -- --seed 43 -n "/^(?:DefaultValuePluginTest#(?:test_works_with_nested_attributes|test_can_specify_default_value_via_association))$/"

Explicitly clearing the cache resolves this issue.

See #47
See #46