intercom 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
data/changes.txt CHANGED
@@ -1,3 +1,6 @@
1
+ 0.0.9
2
+ - add support for settings/updating url attribute for message_threads
3
+
1
4
  0.0.8
2
5
  - add support for updating last request time for user through either last_request_at or last_impression_at
3
6
 
@@ -98,6 +98,17 @@ module Intercom
98
98
  @attributes["read"]
99
99
  end
100
100
 
101
+ # @return [String]
102
+ # @param [String] read the url that was being viewed when the comment was sent
103
+ def url=(url)
104
+ @attributes["url"] = url
105
+ end
106
+
107
+ # @return [String]
108
+ def url
109
+ @attributes["url"]
110
+ end
111
+
101
112
  # @return [Array<Message>]
102
113
  def messages
103
114
  @attributes["messages"].map {|message_hash| Message.new(message_hash)}
@@ -1,3 +1,3 @@
1
1
  module Intercom #:nodoc:
2
- VERSION = "0.0.8"
2
+ VERSION = "0.0.9"
3
3
  end
@@ -34,10 +34,10 @@ describe "/v1/messages_threads" do
34
34
  end
35
35
 
36
36
  it "sets/gets allowed keys" do
37
- params = {"email" => "me@example.com", :user_id => "abc123", "thread_id" => "123", "body" => "hello world", "read" => true}
37
+ params = {"email" => "me@example.com", :user_id => "abc123", "thread_id" => "123", "body" => "hello world", "read" => true, "url" => "http://example.com"}
38
38
  message_thread = Intercom::MessageThread.new(params)
39
39
  message_thread.to_hash.keys.sort.must_equal params.keys.map(&:to_s).sort
40
- params.keys.each do | key|
40
+ params.keys.each do |key|
41
41
  message_thread.send(key).must_equal params[key]
42
42
  end
43
43
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: intercom
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2013-01-08 00:00:00.000000000 Z
14
+ date: 2013-01-16 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: minitest