landslider 0.5.15 → 0.5.16

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
2
  :major: 0
3
3
  :minor: 5
4
- :patch: 15
4
+ :patch: 16
5
5
  :build:
data/landslider.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{landslider}
8
- s.version = "0.5.15"
8
+ s.version = "0.5.16"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Jay Prall"]
12
- s.date = %q{2011-05-22}
12
+ s.date = %q{2011-05-23}
13
13
  s.description = %q{Landslider is a ruby interface to the Landslide SOAP-based API}
14
14
  s.email = %q{jay@j4y.net}
15
15
  s.extra_rdoc_files = [
@@ -82,6 +82,18 @@ Gem::Specification.new do |s|
82
82
  s.require_paths = ["lib"]
83
83
  s.rubygems_version = %q{1.6.2}
84
84
  s.summary = %q{Landslide Ruby}
85
+ s.test_files = [
86
+ "test/get_account_types_test.rb",
87
+ "test/get_accounts_test.rb",
88
+ "test/landslider_test.rb",
89
+ "test/run_mylist_by_id_test.rb",
90
+ "test/test_helper.rb",
91
+ "test/ws_account_note_search_test.rb",
92
+ "test/ws_contact_note_search_test.rb",
93
+ "test/ws_lead_note_search_test.rb",
94
+ "test/ws_opportunity_note_search_test.rb",
95
+ "test/ws_search_test.rb"
96
+ ]
85
97
 
86
98
  if s.respond_to? :specification_version then
87
99
  s.specification_version = 3
@@ -1,7 +1,7 @@
1
1
  class Landslider
2
2
 
3
- # @deprecated Use {#WsSearchCriterion} instead.
3
+ # @deprecated Use {Landslider::WsSearchCriterion} instead.
4
4
  class WsAccountSearch < WsSearch
5
5
  end
6
-
6
+
7
7
  end
@@ -1,7 +1,7 @@
1
1
  class Landslider
2
2
 
3
- # @deprecated Use {#WsSearchCriterion} instead.
3
+ # @deprecated Use {Landslider::WsSearchCriterion} instead.
4
4
  class WsOpportunitySearch < WsSearch
5
5
  end
6
-
6
+
7
7
  end
data/lib/landslider.rb CHANGED
@@ -552,7 +552,8 @@ class Landslider < Handsoap::Service
552
552
  :created_by => xml_to_int(node, './createdBy/text()'),
553
553
  :created_on => xml_to_str(node, './createdOn/text()'),
554
554
  :archived_by => xml_to_str(node, './archivedBy/text()'),
555
- :sync_with_quickbooks => xml_to_str(node, './isSyncWithQuickbooks/text()'),
555
+ :account_type => xml_to_str(node, './accountType/accountType/text()'),
556
+ :account_type_id => xml_to_int(node, './accountType/accountTypeId/text()'),
556
557
  :custom_fields => node.xpath('./customFields', ns).map { |child| parse_custom_field(child) }
557
558
  }
558
559
 
@@ -12,7 +12,7 @@ class GetAccountsTest < Test::Unit::TestCase
12
12
  def test_get_accounts_without_search
13
13
 
14
14
  result = Landslider.get_accounts($sesson_id1)
15
-
15
+
16
16
  assert_not_nil result
17
17
  assert_equal false, result[:error]
18
18
  assert_kind_of Array, result[:accounts]
@@ -36,11 +36,12 @@ class GetAccountsTest < Test::Unit::TestCase
36
36
  search = Landslider::WsSearch.new
37
37
  search.search_criteria = Landslider::WsSearchCriterion.new('AccountTypeId', 'Equals', '1539484')
38
38
  result = Landslider.get_accounts($sesson_id1, search)
39
-
39
+
40
40
  assert_not_nil result
41
41
  assert_equal false, result[:error]
42
42
  assert_kind_of Array, result[:accounts]
43
43
  assert_equal 2, result[:accounts].size
44
+ assert result[:accounts].all? { |a| a[:account_type_id] == 1539484}, "account type id should match search crit"
44
45
 
45
46
  end
46
47
 
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: landslider
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.5.15
5
+ version: 0.5.16
6
6
  platform: ruby
7
7
  authors:
8
8
  - Jay Prall
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-05-22 00:00:00 -04:00
13
+ date: 2011-05-23 00:00:00 -04:00
14
14
  default_executable:
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
@@ -154,5 +154,14 @@ rubygems_version: 1.6.2
154
154
  signing_key:
155
155
  specification_version: 3
156
156
  summary: Landslide Ruby
157
- test_files: []
158
-
157
+ test_files:
158
+ - test/get_account_types_test.rb
159
+ - test/get_accounts_test.rb
160
+ - test/landslider_test.rb
161
+ - test/run_mylist_by_id_test.rb
162
+ - test/test_helper.rb
163
+ - test/ws_account_note_search_test.rb
164
+ - test/ws_contact_note_search_test.rb
165
+ - test/ws_lead_note_search_test.rb
166
+ - test/ws_opportunity_note_search_test.rb
167
+ - test/ws_search_test.rb