Browse files

updated gem specs

  • Loading branch information...
1 parent 8597b26 commit 6aa9be6fd12aaa5e0e77badedb3c28be179a243a @vjebelev committed Dec 23, 2011
Showing with 25 additions and 27 deletions.
  1. +4 −0 CHANGELOG
  2. +1 −1 TODO
  3. +3 −1 lib/netsuite_client.rb
  4. +7 −20 lib/netsuite_client/string.rb
  5. +5 −0 lib/netsuite_client/symbol.rb
  6. +4 −4 netsuite_client.gemspec
  7. +1 −1 test/netsuite_client_test.rb
View
4 CHANGELOG
@@ -1,4 +1,8 @@
+=== 1.1 2011-12-23
+
+ * made it work with ruby 1.9.2 (spews some warnings though)
+
=== 1.0.1 2011-12-21
* fixed scope of method full_basic_search (was private by mistake)
View
2 TODO
@@ -1 +1 @@
-add support for ruby 1.9.2
+replace soap4r, at least for runtime
View
4 lib/netsuite_client.rb
@@ -1,6 +1,9 @@
$:.unshift(File.dirname(__FILE__)) unless
$:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
+require 'netsuite_client/string'
+require 'netsuite_client/symbol'
+
require 'rubygems'
gem 'soap4r'
@@ -16,7 +19,6 @@
require "netsuite_client/soap_netsuite_#{DEFAULT_NS_WSDL_VERSION}"
end
-require 'netsuite_client/string'
require 'netsuite_client/netsuite_exception'
require 'netsuite_client/netsuite_result'
require 'netsuite_client/client'
View
27 lib/netsuite_client/string.rb
@@ -3,28 +3,15 @@
# #const_defined? and changes their default behavior.
class String
- if Module.method(:const_get).arity == 1
- def constantize #:nodoc:
- names = self.split('::')
- names.shift if names.empty? || names.first.empty?
+ def constantize #:nodoc:
+ names = self.split('::')
+ names.shift if names.empty? || names.first.empty?
- constant = Object
- names.each do |name|
- constant = constant.const_defined?(name) ? constant.const_get(name) : constant.const_missing(name)
- end
- constant
- end
- else
- def constantize(camel_cased_word) #:nodoc:
- names = camel_cased_word.split('::')
- names.shift if names.empty? || names.first.empty?
-
- constant = Object
- names.each do |name|
- constant = constant.const_get(name, false) || constant.const_missing(name)
- end
- constant
+ constant = Object
+ names.each do |name|
+ constant = constant.const_defined?(name) ? constant.const_get(name) : constant.const_missing(name)
end
+ constant
end
def self.random_string(len = 8)
View
5 lib/netsuite_client/symbol.rb
@@ -0,0 +1,5 @@
+class Symbol
+ def downcase
+ to_s.downcase
+ end
+end
View
8 netsuite_client.gemspec
@@ -2,15 +2,15 @@
Gem::Specification.new do |s|
s.name = %q{netsuite_client}
- s.version = "1.0.1"
+ s.version = "1.1"
- s.required_ruby_version = '~> 1.8.7'
+ s.required_ruby_version = '>= 1.8.6'
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Vlad Jebelev"]
- s.date = %q{2011-11-25}
+ s.date = %q{2011-12-23}
s.description = %q{Ruby soap4r-based Netsuite client.}
s.email = ["vlad@jebelev.com"]
- s.rdoc_options += ['-m', 'README.rdoc', '-x', 'lib/netsuite_client/soap*.*', 'lib/netsuite_client/netsuite*', 'lib/netsuite_client/string.rb', 'lib/netsuite_client/client.rb', 'README.rdoc']
+ s.rdoc_options += ['-m', 'README.rdoc', '-x', 'lib/netsuite_client/soap*.*', 'lib/netsuite_client/netsuite*', 'lib/netsuite_client/string.rb', 'lib/netsuite_client/symbol.rb', 'lib/netsuite_client/client.rb', 'README.rdoc']
s.extra_rdoc_files = ["CHANGELOG", "Manifest.txt"]
s.files = ["CHANGELOG", "Manifest.txt", "README.rdoc", "Rakefile", "TODO", "netsuite_client.gemspec"] + Dir['lib/**/*.rb'] + Dir['test/*.rb']
s.homepage = %q{http://rubygems.org/gems/netsuite_client}
View
2 test/netsuite_client_test.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/test_helper.rb'
+require File.expand_path(File.join(File.dirname(__FILE__), 'test_helper'))
class NetsuiteClientClient < Test::Unit::TestCase
include NetSuite::SOAP

0 comments on commit 6aa9be6

Please sign in to comment.