oracle_enhanced 1.2.5 → 1.3.0.pre

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/Rakefile CHANGED
@@ -11,7 +11,7 @@ Oracle "enhanced" ActiveRecord adapter contains useful additional methods for wo
11
11
  This adapter is superset of original ActiveRecord Oracle adapter.
12
12
  EOS
13
13
  gem.email = "raimonds.simanovskis@gmail.com"
14
- gem.homepage = "http://github.com/plukevdh/oracle-enhanced"
14
+ gem.homepage = "http://github.com/rsim/oracle-enhanced"
15
15
  gem.authors = ["Raimonds Simanovskis"]
16
16
  gem.add_dependency "activerecord", ">= 2.0.0"
17
17
  gem.add_development_dependency "rspec", ">= 1.2.9"
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.5
1
+ 1.3.0.pre
@@ -15,14 +15,14 @@ namespace :db do
15
15
  namespace :structure do
16
16
  redefine_task :dump => :environment do
17
17
  abcs = ActiveRecord::Base.configurations
18
- ActiveRecord::Base.establish_connection(abcs[RAILS_ENV])
19
- File.open("db/#{RAILS_ENV}_structure.sql", "w+") { |f| f << ActiveRecord::Base.connection.structure_dump }
20
- File.open("db/#{RAILS_ENV}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.structure_dump_fk_constraints }
18
+ ActiveRecord::Base.establish_connection(abcs[Rails.env])
19
+ File.open("db/#{Rails.env}_structure.sql", "w+") { |f| f << ActiveRecord::Base.connection.structure_dump }
20
+ File.open("db/#{Rails.env}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.structure_dump_fk_constraints }
21
21
  if ActiveRecord::Base.connection.supports_migrations?
22
- File.open("db/#{RAILS_ENV}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.dump_schema_information }
22
+ File.open("db/#{Rails.env}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.dump_schema_information }
23
23
  end
24
- if abcs[RAILS_ENV]['structure_dump'] == "db_stored_code"
25
- File.open("db/#{RAILS_ENV}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.structure_dump_db_stored_code }
24
+ if abcs[Rails.env]['structure_dump'] == "db_stored_code"
25
+ File.open("db/#{Rails.env}_structure.sql", "a") { |f| f << ActiveRecord::Base.connection.structure_dump_db_stored_code }
26
26
  end
27
27
 
28
28
  end
@@ -32,7 +32,7 @@ namespace :db do
32
32
  redefine_task :clone_structure => [ "db:structure:dump", "db:test:purge" ] do
33
33
  abcs = ActiveRecord::Base.configurations
34
34
  ActiveRecord::Base.establish_connection(:test)
35
- IO.readlines("db/#{RAILS_ENV}_structure.sql").join.split("\n\n").each do |ddl|
35
+ IO.readlines("db/#{Rails.env}_structure.sql").join.split("\n\n").each do |ddl|
36
36
  ddl.chop! if ddl.last == ";"
37
37
  ActiveRecord::Base.connection.execute(ddl) unless ddl.blank?
38
38
  end
@@ -128,8 +128,8 @@ module ActiveRecord
128
128
  end
129
129
  private :add_order_with_lobs!
130
130
  #:stopdoc:
131
- alias_method :add_order_without_lobs!, :add_order!
132
- alias_method :add_order!, :add_order_with_lobs!
131
+ alias_method :add_order!, :add_order_with_lobs! #rails 3 issues
132
+ alias_method :add_order_without_lobs!, :add_order!
133
133
  #:startdoc:
134
134
  end
135
135
 
@@ -1641,7 +1641,7 @@ require 'active_record/connection_adapters/oracle_enhanced_dirty'
1641
1641
  begin
1642
1642
  require 'active_record/connection_adapters/oracle_enhanced_tasks'
1643
1643
  rescue LoadError
1644
- end if defined?(RAILS_ROOT)
1644
+ end if defined?(Rails.root)
1645
1645
 
1646
1646
  # Handles quoting of oracle reserved words
1647
1647
  require 'active_record/connection_adapters/oracle_enhanced_reserved_words'
@@ -53,8 +53,8 @@ if defined?(RUBY_ENGINE) && RUBY_ENGINE == 'ruby' && RUBY_VERSION >= '1.9'
53
53
 
54
54
  rescue LoadError
55
55
  warning_message = "WARNING: Please install unicode_utils gem to support Unicode aware upcase and downcase for String#mb_chars"
56
- if defined?(RAILS_DEFAULT_LOGGER)
57
- RAILS_DEFAULT_LOGGER.warn warning_message
56
+ if !(Rails.logger.nil?)
57
+ Rails.logger.warn warning_message
58
58
  else
59
59
  STDERR.puts warning_message
60
60
  end
@@ -1,5 +1,5 @@
1
1
  # implementation idea taken from JDBC adapter
2
- if defined?(Rake.application) && Rake.application && ActiveRecord::Base.configurations[RAILS_ENV]['adapter'] == 'oracle_enhanced'
2
+ if defined?(Rake.application) && Rake.application && ActiveRecord::Base.configurations[Rails.env]['adapter'] == 'oracle_enhanced'
3
3
  oracle_enhanced_rakefile = File.dirname(__FILE__) + "/oracle_enhanced.rake"
4
4
  if Rake.application.lookup("environment")
5
5
  # rails tasks already defined; load the override tasks now
@@ -0,0 +1,3 @@
1
+ #dummy for easier require
2
+
3
+ require 'active_record/connection_adapters/oracle_enhanced_adapter'
@@ -0,0 +1,98 @@
1
+ # Generated by jeweler
2
+ # DO NOT EDIT THIS FILE DIRECTLY
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
4
+ # -*- encoding: utf-8 -*-
5
+
6
+ Gem::Specification.new do |s|
7
+ s.name = %q{oracle_enhanced}
8
+ s.version = "1.3.0.pre"
9
+
10
+ s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
11
+ s.authors = ["Raimonds Simanovskis"]
12
+ s.date = %q{2010-03-03}
13
+ s.description = %q{Oracle "enhanced" ActiveRecord adapter contains useful additional methods for working with new and legacy Oracle databases.
14
+ This adapter is superset of original ActiveRecord Oracle adapter.
15
+ }
16
+ s.email = %q{raimonds.simanovskis@gmail.com}
17
+ s.extra_rdoc_files = [
18
+ "README.rdoc"
19
+ ]
20
+ s.files = [
21
+ ".gitignore",
22
+ "History.txt",
23
+ "License.txt",
24
+ "Manifest.txt",
25
+ "README.rdoc",
26
+ "Rakefile",
27
+ "VERSION",
28
+ "lib/active_record/connection_adapters/emulation/oracle_adapter.rb",
29
+ "lib/active_record/connection_adapters/oracle_enhanced.rake",
30
+ "lib/active_record/connection_adapters/oracle_enhanced_adapter.rb",
31
+ "lib/active_record/connection_adapters/oracle_enhanced_connection.rb",
32
+ "lib/active_record/connection_adapters/oracle_enhanced_core_ext.rb",
33
+ "lib/active_record/connection_adapters/oracle_enhanced_cpk.rb",
34
+ "lib/active_record/connection_adapters/oracle_enhanced_dirty.rb",
35
+ "lib/active_record/connection_adapters/oracle_enhanced_jdbc_connection.rb",
36
+ "lib/active_record/connection_adapters/oracle_enhanced_oci_connection.rb",
37
+ "lib/active_record/connection_adapters/oracle_enhanced_procedures.rb",
38
+ "lib/active_record/connection_adapters/oracle_enhanced_reserved_words.rb",
39
+ "lib/active_record/connection_adapters/oracle_enhanced_schema_definitions.rb",
40
+ "lib/active_record/connection_adapters/oracle_enhanced_schema_dumper.rb",
41
+ "lib/active_record/connection_adapters/oracle_enhanced_schema_statements_ext.rb",
42
+ "lib/active_record/connection_adapters/oracle_enhanced_tasks.rb",
43
+ "lib/active_record/connection_adapters/oracle_enhanced_version.rb",
44
+ "lib/oracle_enhanced.rb",
45
+ "oracle_enhanced.gemspec",
46
+ "spec/active_record/connection_adapters/oracle_enhanced_adapter_spec.rb",
47
+ "spec/active_record/connection_adapters/oracle_enhanced_adapter_structure_dumper_spec.rb",
48
+ "spec/active_record/connection_adapters/oracle_enhanced_connection_spec.rb",
49
+ "spec/active_record/connection_adapters/oracle_enhanced_core_ext_spec.rb",
50
+ "spec/active_record/connection_adapters/oracle_enhanced_cpk_spec.rb",
51
+ "spec/active_record/connection_adapters/oracle_enhanced_data_types_spec.rb",
52
+ "spec/active_record/connection_adapters/oracle_enhanced_dbms_output_spec.rb",
53
+ "spec/active_record/connection_adapters/oracle_enhanced_dirty_spec.rb",
54
+ "spec/active_record/connection_adapters/oracle_enhanced_emulate_oracle_adapter_spec.rb",
55
+ "spec/active_record/connection_adapters/oracle_enhanced_procedures_spec.rb",
56
+ "spec/active_record/connection_adapters/oracle_enhanced_schema_dump_spec.rb",
57
+ "spec/active_record/connection_adapters/oracle_enhanced_schema_spec.rb",
58
+ "spec/spec.opts",
59
+ "spec/spec_helper.rb"
60
+ ]
61
+ s.homepage = %q{http://github.com/rsim/oracle-enhanced}
62
+ s.rdoc_options = ["--charset=UTF-8"]
63
+ s.require_paths = ["lib"]
64
+ s.rubygems_version = %q{1.3.6}
65
+ s.summary = %q{Oracle enhanced adapter for ActiveRecord}
66
+ s.test_files = [
67
+ "spec/active_record/connection_adapters/oracle_enhanced_adapter_spec.rb",
68
+ "spec/active_record/connection_adapters/oracle_enhanced_adapter_structure_dumper_spec.rb",
69
+ "spec/active_record/connection_adapters/oracle_enhanced_connection_spec.rb",
70
+ "spec/active_record/connection_adapters/oracle_enhanced_core_ext_spec.rb",
71
+ "spec/active_record/connection_adapters/oracle_enhanced_cpk_spec.rb",
72
+ "spec/active_record/connection_adapters/oracle_enhanced_data_types_spec.rb",
73
+ "spec/active_record/connection_adapters/oracle_enhanced_dbms_output_spec.rb",
74
+ "spec/active_record/connection_adapters/oracle_enhanced_dirty_spec.rb",
75
+ "spec/active_record/connection_adapters/oracle_enhanced_emulate_oracle_adapter_spec.rb",
76
+ "spec/active_record/connection_adapters/oracle_enhanced_procedures_spec.rb",
77
+ "spec/active_record/connection_adapters/oracle_enhanced_schema_dump_spec.rb",
78
+ "spec/active_record/connection_adapters/oracle_enhanced_schema_spec.rb",
79
+ "spec/spec_helper.rb"
80
+ ]
81
+
82
+ if s.respond_to? :specification_version then
83
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
84
+ s.specification_version = 3
85
+
86
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
87
+ s.add_runtime_dependency(%q<activerecord>, [">= 2.0.0"])
88
+ s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
89
+ else
90
+ s.add_dependency(%q<activerecord>, [">= 2.0.0"])
91
+ s.add_dependency(%q<rspec>, [">= 1.2.9"])
92
+ end
93
+ else
94
+ s.add_dependency(%q<activerecord>, [">= 2.0.0"])
95
+ s.add_dependency(%q<rspec>, [">= 1.2.9"])
96
+ end
97
+ end
98
+
data/spec/spec_helper.rb CHANGED
@@ -40,11 +40,14 @@ if ENV['RAILS_GEM_VERSION'] >= '2.3'
40
40
  else
41
41
  require 'action_controller/session/active_record_store'
42
42
  end
43
- if !defined?(RUBY_ENGINE) || RUBY_ENGINE == 'ruby'
44
- gem 'ruby-oci8', '>=2.0.4'
43
+ if !defined?(RUBY_ENGINE)
44
+ gem 'ruby-oci8', '=2.0.3'
45
+ require 'oci8'
46
+ elsif RUBY_ENGINE == 'ruby'
47
+ gem 'ruby-oci8', '=2.0.3'
45
48
  require 'oci8'
46
49
  elsif RUBY_ENGINE == 'jruby'
47
- gem 'activerecord-jdbc-adapter'
50
+ gem "activerecord-jdbc-adapter"
48
51
  require 'active_record/connection_adapters/jdbc_adapter'
49
52
  end
50
53
 
metadata CHANGED
@@ -1,12 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oracle_enhanced
3
3
  version: !ruby/object:Gem::Version
4
- prerelease: false
4
+ prerelease: true
5
5
  segments:
6
6
  - 1
7
- - 2
8
- - 5
9
- version: 1.2.5
7
+ - 3
8
+ - 0
9
+ - pre
10
+ version: 1.3.0.pre
10
11
  platform: ruby
11
12
  authors:
12
13
  - Raimonds Simanovskis
@@ -14,7 +15,7 @@ autorequire:
14
15
  bindir: bin
15
16
  cert_chain: []
16
17
 
17
- date: 2010-03-08 00:00:00 -05:00
18
+ date: 2010-03-03 00:00:00 -05:00
18
19
  default_executable:
19
20
  dependencies:
20
21
  - !ruby/object:Gem::Dependency
@@ -80,6 +81,8 @@ files:
80
81
  - lib/active_record/connection_adapters/oracle_enhanced_schema_statements_ext.rb
81
82
  - lib/active_record/connection_adapters/oracle_enhanced_tasks.rb
82
83
  - lib/active_record/connection_adapters/oracle_enhanced_version.rb
84
+ - lib/oracle_enhanced.rb
85
+ - oracle_enhanced.gemspec
83
86
  - spec/active_record/connection_adapters/oracle_enhanced_adapter_spec.rb
84
87
  - spec/active_record/connection_adapters/oracle_enhanced_adapter_structure_dumper_spec.rb
85
88
  - spec/active_record/connection_adapters/oracle_enhanced_connection_spec.rb
@@ -95,7 +98,7 @@ files:
95
98
  - spec/spec.opts
96
99
  - spec/spec_helper.rb
97
100
  has_rdoc: true
98
- homepage: http://github.com/plukevdh/oracle-enhanced
101
+ homepage: http://github.com/rsim/oracle-enhanced
99
102
  licenses: []
100
103
 
101
104
  post_install_message:
@@ -112,11 +115,13 @@ required_ruby_version: !ruby/object:Gem::Requirement
112
115
  version: "0"
113
116
  required_rubygems_version: !ruby/object:Gem::Requirement
114
117
  requirements:
115
- - - ">="
118
+ - - ">"
116
119
  - !ruby/object:Gem::Version
117
120
  segments:
118
- - 0
119
- version: "0"
121
+ - 1
122
+ - 3
123
+ - 1
124
+ version: 1.3.1
120
125
  requirements: []
121
126
 
122
127
  rubyforge_project: