liveh2o/protobuf-activerecord — pull request #10 by decriptor (2013-11-15 06:52:44+00:00)
Title: Convert from rspec to minitest

I'm not very familiar with this stuff. This is about as far as I've gotten with this. Sorry its not finished.

If you want I can squash all of these commits into one.

Here is the rake output ->
(in /Users/sshaw/code/protobuf-activerecord)

*** Mocha deprecation warning: Change `require 'mocha'` to `require 'mocha/setup'`.

-- create_table(:users)
-> 0.0047s
-- initialize_schema_migrations_table()
-> 0.0030s
Coverage report generated for RSpec to /Users/sshaw/code/protobuf-activerecord/coverage. 213 / 403 LOC (52.85%) covered.
Run options: --seed 39590

# Running tests:

...............................E.......................[WARNING] UserMessage#email_domain field usage is deprecated.
[WARNING] UserMessage#email_domain field usage is deprecated.
..[WARNING] UserMessage#email_domain field usage is deprecated.
[WARNING] UserMessage#email_domain field usage is deprecated.
...................F...

Finished tests in 0.117135s, 682.9726 tests/s, 648.8240 assertions/s.

1) Error:
Protobuf::ActiveRecord::Scope::.search_scope::when a searchable field uses a non-existant scope#test_0001_raises an exception:
TypeError: class or module required
(eval):4:in `must_raise'
/Users/sshaw/code/protobuf-activerecord/spec/protobuf/active_record/scope_spec.rb:45:in `block (4 levels) in '

2) Failure:
Protobuf::ActiveRecord::Transformation::.attributes_from_proto::when a transformer is not defined for the attribute#test_0001_converts the field value [/Users/sshaw/code/protobuf-activerecord/spec/protobuf/active_record/transformation_spec.rb:143]:
--- expected
+++ actual
@@ -1 +1 @@
-{:first_name=>"foo", :last_name=>"bar", :email=>"foo@test.co"}
+{:first_name=>"foo", :last_name=>"bar", :email=>nil}

80 tests, 76 assertions, 1 failures, 1 errors, 0 skips
rake aborted!
Command failed with status (1): [ruby -I"lib:spec" -I"/usr/local/Cellar/ruby/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib" "/usr/local/Cellar/ruby/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/rake_test_loader.rb" "spec/**/*_spec.rb" ]

Tasks: TOP => default => test
(See full trace by running task with --trace)