woodpecker 0.1.3 → 0.1.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 915cefe318c08f7e97ad1b5c19ac0b3c150782f4
4
- data.tar.gz: 60ec21a498d934d32bdbc1c18e9d06eb9bb4ea29
2
+ SHA256:
3
+ metadata.gz: e5c6cd3cbe637906e3fd0785b1cc26e0cac56d9a2629628fb8d70c651126a203
4
+ data.tar.gz: 26e3bebe119de905d6417f102f00f09b6fb9c5afa64d0694894a4d0162cacf33
5
5
  SHA512:
6
- metadata.gz: 2fc9aad53f4d6242815f9ba2a4988e591759553b5899e67ba95b53aadb90cb65db0709696d5657c449f6fe3b7685d628909b5b6124b25d4d31c80521cd4055f7
7
- data.tar.gz: 1aa083c1ac61c7b067879fdc30502a63f809d6c5c61967df0e624db1151d31125d59ea7105d66334e363434587c08fd48fd8d5ed2fed7fbf51757ce074ce7366
6
+ metadata.gz: ebe94eeaffe19ce54bbfae04f8a4937d31480ebe4283443c4fb020b8aad9c98e39a37ea1b14da3bed1fc8201358fc3df08837133c685bacc3bd0bbeae2ce5e89
7
+ data.tar.gz: 909cb0a4d32fc1d4be7ad0a129b0097154a024965d366f0e86cf4b1fd8e52ccf5c32e6d656f26439f6c6183e6d99c584045dfc76feabdb8ba8314aaff3811c19
data/.gitignore CHANGED
@@ -7,3 +7,4 @@
7
7
  /pkg/
8
8
  /spec/reports/
9
9
  /tmp/
10
+ .env
@@ -1,5 +1,15 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.4 (2018-06-17)
4
+
5
+ * Actually set `dummy_password` to `X` if it wasn't provided.
6
+ * Use wrap method instead of `Kernel#Array` since it behaves different than expected on a Hash.
7
+ * Use `Time::parse` instead of `Time#iso801` because Woodpecker API doesn't return a valid ISO8601 date.
8
+
9
+ ## 0.1.3 (2018-05-17)
10
+
11
+ * Send `Content-Type: application/json` on POST requests to the API.
12
+
3
13
  ## 0.1.2 (2016-08-17)
4
14
 
5
15
  ### Changes
@@ -10,8 +20,8 @@
10
20
 
11
21
  ### Changes
12
22
 
13
- * `add_prospects_campaign` and `add_prospects_list` now use Kernel#Array so that users don't have to wrap single objects
23
+ * `add_prospects_campaign` and `add_prospects_list` now use Kernel#Array so that users don't have to wrap single objects.
14
24
 
15
25
  ## 0.1.0 (2016-08-02)
16
26
 
17
- * Initial release
27
+ * Initial release.
data/README.md CHANGED
@@ -39,6 +39,10 @@ Woodpecker.configuration.api_key
39
39
  Woodpecker.configuration.dummy_password
40
40
  ```
41
41
 
42
+ ## Changelog
43
+
44
+ All changes are documented in [CHANGELOG.md](https://github.com/Quintasan/woodpecker/blob/master/CHANGELOG.md)
45
+
42
46
  ## Development
43
47
 
44
48
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -8,4 +8,8 @@ require 'woodpecker'
8
8
  # with your gem easier. You can also use a different console, if you like.
9
9
 
10
10
  require 'pry'
11
+ Woodpecker.configure do |c|
12
+ c.api_key = ENV["API_KEY"]
13
+ c.dummy_password = "X"
14
+ end
11
15
  Pry.start
@@ -1,5 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'time'
4
+
3
5
  module Woodpecker
4
6
  class Campaign
5
7
  attr_accessor :id, :name, :status, :from_name, :from_email, :created
@@ -10,7 +12,7 @@ module Woodpecker
10
12
  @status = campaign[:status]
11
13
  @from_name = campaign[:from_name]
12
14
  @from_email = campaign[:from_email]
13
- @created = Time.iso8601(campaign[:created])
15
+ @created = Time.parse(campaign[:created])
14
16
  end
15
17
  end
16
18
  end
@@ -17,8 +17,7 @@ module Woodpecker
17
17
  end
18
18
 
19
19
  def dummy_password
20
- raise Errors::Configuration, 'Dummy password is missing!' unless @dummy_password
21
- @dummy_password
20
+ @dummy_password ||= "X"
22
21
  end
23
22
  end
24
23
  end
@@ -13,7 +13,7 @@ module Woodpecker
13
13
  end
14
14
 
15
15
  def patch
16
- 3
16
+ 4
17
17
  end
18
18
 
19
19
  def to_a
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: woodpecker
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michał Zając
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-05-17 00:00:00.000000000 Z
11
+ date: 2018-05-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -155,7 +155,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
155
155
  version: '0'
156
156
  requirements: []
157
157
  rubyforge_project:
158
- rubygems_version: 2.6.13
158
+ rubygems_version: 2.7.6
159
159
  signing_key:
160
160
  specification_version: 4
161
161
  summary: Simple Woodpecker API client