Skip to content

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
...
  • 3 commits
  • 5 files changed
  • 0 commit comments
  • 1 contributor
View
5 HISTORY.md
@@ -1,3 +1,8 @@
+# 0.14.3
+ * Feb 21, 2012
+
+ - Fix yaml serialization of non DJ models
+
# 0.14.2
* Feb 21, 2012
View
2 lib/apartment/delayed_job/active_record.rb
@@ -15,7 +15,7 @@ def self.yaml_new(klass, tag, val)
# Rails > 3.0 now uses encode_with to determine what to encode with yaml
# @override to include database attribute
def encode_with_with_database(coder)
- coder['database'] = database
+ coder['database'] = @database if @database.present?
encode_with_without_database(coder)
end
alias_method_chain :encode_with, :database
View
2 lib/apartment/delayed_job/requirements.rb
@@ -1,4 +1,4 @@
-require 'apartment/delayed_job/enqueue'
+require 'apartment/delayed_job/active_record' # ensure that our AR hooks are loaded when queueing
module Apartment
module Delayed
View
2 lib/apartment/version.rb
@@ -1,3 +1,3 @@
module Apartment
- VERSION = "0.14.2"
+ VERSION = "0.14.3"
end
View
25 spec/integration/delayed_job_integration_spec.rb
@@ -30,31 +30,6 @@
Apartment::Test.reset
end
- describe Apartment::Delayed::Job do
- context "#enqueue" do
-
- before do
- Apartment::Database.reset
- end
-
- it "should queue up jobs in the public schema" do
- dj_count = Delayed::Job.count
- Apartment::Database.switch database
- Apartment::Delayed::Job.enqueue FakeDjClass.new
- Apartment::Database.reset
-
- Delayed::Job.count.should == dj_count + 1
- end
-
- it "should not queue jobs in the current schema" do
- Apartment::Database.switch database
- expect {
- Apartment::Delayed::Job.enqueue FakeDjClass.new
- }.to_not change(Delayed::Job, :count) # because we will still be on the `database` schema, not public
- end
- end
- end
-
describe Apartment::Delayed::Requirements do
before do

No commit comments for this range

Something went wrong with that request. Please try again.