codeclimate-services 1.9.7 → 1.9.8
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 +4 -4
- data/lib/axiom/types/token.rb +7 -0
- data/lib/cc/service.rb +1 -0
- data/lib/cc/services/asana.rb +2 -2
- data/lib/cc/services/campfire.rb +1 -1
- data/lib/cc/services/flowdock.rb +1 -1
- data/lib/cc/services/github_issues.rb +1 -1
- data/lib/cc/services/github_pull_requests.rb +1 -1
- data/lib/cc/services/gitlab_merge_requests.rb +1 -1
- data/lib/cc/services/hipchat.rb +1 -1
- data/lib/cc/services/lighthouse.rb +1 -1
- data/lib/cc/services/pivotal_tracker.rb +1 -1
- data/lib/cc/services/version.rb +1 -1
- data/spec/axiom/types/token_spec.rb +14 -0
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cd62622c4effd89f89c9285ec07b7cd2798148b5
|
4
|
+
data.tar.gz: 746d956aa4ffe90f01b60b138189f3470d0aa824
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e5c2d4cb11d2af026062570d9d7d2cdba70c301fb8f82058538af93c5dae4d5b22d571fe697d3ceb015434770236d6f8e9befbc7f92a4605a01b3092de374ded
|
7
|
+
data.tar.gz: 13adce202c161bed06e78f28439e375834135b365e307234e5f45f1ccdd0c280d5716aa59ec218452968b2c2f4b0bd4d3c9411f5c75a05a8159267e803afc1f6
|
data/lib/cc/service.rb
CHANGED
data/lib/cc/services/asana.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
class CC::Service::Asana < CC::Service
|
2
2
|
class Config < CC::Service::Config
|
3
|
-
attribute :personal_access_token, Axiom::Types::
|
4
|
-
attribute :api_key, Axiom::Types::
|
3
|
+
attribute :personal_access_token, Axiom::Types::Token, label: "Personal Access Token"
|
4
|
+
attribute :api_key, Axiom::Types::Token, label: "API key (Deprecated)"
|
5
5
|
|
6
6
|
attribute :workspace_id, Axiom::Types::String, label: "Workspace ID"
|
7
7
|
|
data/lib/cc/services/campfire.rb
CHANGED
@@ -2,7 +2,7 @@ class CC::Service::Campfire < CC::Service
|
|
2
2
|
class Config < CC::Service::Config
|
3
3
|
attribute :subdomain, Axiom::Types::String,
|
4
4
|
description: "The Campfire subdomain for the account"
|
5
|
-
attribute :token, Axiom::Types::
|
5
|
+
attribute :token, Axiom::Types::Token,
|
6
6
|
description: "Your Campfire API auth token"
|
7
7
|
attribute :room_id, Axiom::Types::String,
|
8
8
|
description: "Check your campfire URL for a room ID. Usually 6 digits."
|
data/lib/cc/services/flowdock.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
class CC::Service::Flowdock < CC::Service
|
2
2
|
class Config < CC::Service::Config
|
3
|
-
attribute :api_token, Axiom::Types::
|
3
|
+
attribute :api_token, Axiom::Types::Token,
|
4
4
|
label: "API Token",
|
5
5
|
description: "The API token of the Flow to send notifications to",
|
6
6
|
link: "https://www.flowdock.com/account/tokens"
|
@@ -1,6 +1,6 @@
|
|
1
1
|
class CC::Service::GitHubIssues < CC::Service
|
2
2
|
class Config < CC::Service::Config
|
3
|
-
attribute :oauth_token, Axiom::Types::
|
3
|
+
attribute :oauth_token, Axiom::Types::Token,
|
4
4
|
label: "OAuth Token",
|
5
5
|
description: "A personal OAuth token with permissions for the repo"
|
6
6
|
attribute :project, Axiom::Types::String,
|
@@ -2,7 +2,7 @@ require "cc/presenters/pull_requests_presenter"
|
|
2
2
|
|
3
3
|
class CC::Service::GitHubPullRequests < CC::PullRequests
|
4
4
|
class Config < CC::Service::Config
|
5
|
-
attribute :oauth_token, Axiom::Types::
|
5
|
+
attribute :oauth_token, Axiom::Types::Token,
|
6
6
|
label: "OAuth Token",
|
7
7
|
description: "A personal OAuth token with permissions for the repo."
|
8
8
|
attribute :base_url, Axiom::Types::String,
|
@@ -4,7 +4,7 @@ class CC::Service::GitlabMergeRequests < CC::PullRequests
|
|
4
4
|
class Config < CC::Service::Config
|
5
5
|
CONTEXT = "codeclimate".freeze
|
6
6
|
|
7
|
-
attribute :access_token, Axiom::Types::
|
7
|
+
attribute :access_token, Axiom::Types::Token,
|
8
8
|
label: "Access Token",
|
9
9
|
description: "A personal access token with permissions for the repo."
|
10
10
|
attribute :base_url, Axiom::Types::String,
|
data/lib/cc/services/hipchat.rb
CHANGED
@@ -3,7 +3,7 @@ class CC::Service::Lighthouse < CC::Service
|
|
3
3
|
attribute :subdomain, Axiom::Types::String,
|
4
4
|
description: "Your Lighthouse subdomain"
|
5
5
|
|
6
|
-
attribute :api_token, Axiom::Types::
|
6
|
+
attribute :api_token, Axiom::Types::Token,
|
7
7
|
label: "API Token",
|
8
8
|
description: "Your Lighthouse API Key (http://help.lighthouseapp.com/kb/api/how-do-i-get-an-api-token)"
|
9
9
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
class CC::Service::PivotalTracker < CC::Service
|
2
2
|
class Config < CC::Service::Config
|
3
|
-
attribute :api_token, Axiom::Types::
|
3
|
+
attribute :api_token, Axiom::Types::Token,
|
4
4
|
description: "Your Pivotal Tracker API Token, from your profile page"
|
5
5
|
|
6
6
|
attribute :project_id, Axiom::Types::String,
|
data/lib/cc/services/version.rb
CHANGED
@@ -0,0 +1,14 @@
|
|
1
|
+
describe Axiom::Types::Token do
|
2
|
+
class TestConfiguration < CC::Service::Config
|
3
|
+
attribute :token_attribute, Token
|
4
|
+
attribute :str_attribute, String
|
5
|
+
end
|
6
|
+
|
7
|
+
it "token type inference" do
|
8
|
+
expect(Axiom::Types::Token).to eq(TestConfiguration.attribute_set[:token_attribute].type)
|
9
|
+
end
|
10
|
+
|
11
|
+
it "string type inference" do
|
12
|
+
expect(Axiom::Types::String).to eq(TestConfiguration.attribute_set[:str_attribute].type)
|
13
|
+
end
|
14
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: codeclimate-services
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.9.
|
4
|
+
version: 1.9.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bryan Helmkamp
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-06-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -149,6 +149,7 @@ files:
|
|
149
149
|
- config/cacert.pem
|
150
150
|
- config/load.rb
|
151
151
|
- lib/axiom/types/password.rb
|
152
|
+
- lib/axiom/types/token.rb
|
152
153
|
- lib/cc/formatters/linked_formatter.rb
|
153
154
|
- lib/cc/formatters/plain_formatter.rb
|
154
155
|
- lib/cc/formatters/snapshot_formatter.rb
|
@@ -190,6 +191,7 @@ files:
|
|
190
191
|
- pull_request_test.rb
|
191
192
|
- service_test.rb
|
192
193
|
- spec/axiom/types/password_spec.rb
|
194
|
+
- spec/axiom/types/token_spec.rb
|
193
195
|
- spec/cc/formatters/snapshot_formatter_spec.rb
|
194
196
|
- spec/cc/presenters/pull_requests_presenter_spec.rb
|
195
197
|
- spec/cc/resolve_spec.rb
|
@@ -242,6 +244,7 @@ specification_version: 4
|
|
242
244
|
summary: Service classes for Code Climate
|
243
245
|
test_files:
|
244
246
|
- spec/axiom/types/password_spec.rb
|
247
|
+
- spec/axiom/types/token_spec.rb
|
245
248
|
- spec/cc/formatters/snapshot_formatter_spec.rb
|
246
249
|
- spec/cc/presenters/pull_requests_presenter_spec.rb
|
247
250
|
- spec/cc/resolve_spec.rb
|