hydra-migrate 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/HISTORY.md CHANGED
@@ -1,3 +1,6 @@
1
+ * 0.2.1 (29 Aug 2013) [Michael Klein]
2
+ * Save without validating (leave object validation to the migration)
3
+
1
4
  * 0.2.0 (27 Aug 2013) [Michael Klein]
2
5
  * Add Dispatcher#migrate_all!(*classes, :to=>version, :path=>path_to_migrations)
3
6
 
@@ -61,11 +61,7 @@ module Hydra
61
61
  migration[:block].call(object, migration[:to], self)
62
62
  object.migrationInfo.migrate(migration[:to])
63
63
  object.current_migration = migration[:to]
64
- unless opts[:dry_run]
65
- unless object.save
66
- raise %{Cannot save #{object.pid}:\n#{object.errors.to_a.join("\n")}}
67
- end
68
- end
64
+ object.save(:validate=>false) unless opts[:dry_run]
69
65
  end
70
66
  object
71
67
  }
@@ -1,5 +1,5 @@
1
1
  module Hydra
2
2
  module Migrate
3
- VERSION = "0.2.0"
3
+ VERSION = "0.2.1"
4
4
  end
5
5
  end
@@ -9,7 +9,7 @@ require 'rspec/autorun'
9
9
 
10
10
  begin
11
11
  require 'simplecov'
12
- SimpleCov.start
12
+ SimpleCov.start { add_filter 'spec/' }
13
13
  rescue LoadError
14
14
  end
15
15
 
@@ -8,7 +8,7 @@ describe Hydra::Migrate do
8
8
  d.field :migrated, :string
9
9
  end
10
10
 
11
- def save
11
+ def save(opts={})
12
12
  true
13
13
  end
14
14
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hydra-migrate
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-08-27 00:00:00.000000000 Z
12
+ date: 2013-08-30 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: active-fedora
OSZAR »