orcid 0.1.1 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.hound.yml +2 -1
- data/CONTRIBUTING.md +213 -0
- data/README.md +2 -5
- data/app/controllers/orcid/profile_requests_controller.rb +11 -1
- data/app/models/orcid/profile_connection.rb +12 -2
- data/app/models/orcid/profile_status.rb +67 -0
- data/app/services/orcid/remote/profile_creation_service.rb +15 -0
- data/app/services/orcid/remote/profile_query_service/response_parser.rb +53 -0
- data/app/services/orcid/remote/profile_query_service.rb +4 -23
- data/app/views/orcid/profile_connections/_authenticated_connection.html.erb +5 -0
- data/app/views/orcid/profile_connections/_options_to_connect_orcid_profile.html.erb +20 -0
- data/app/views/orcid/profile_connections/_orcid_connector.html.erb +15 -18
- data/app/views/orcid/profile_connections/_pending_connection.html.erb +11 -0
- data/app/views/orcid/profile_connections/_profile_request_pending.html.erb +5 -0
- data/config/locales/orcid.en.yml +1 -1
- data/lib/orcid/configuration/provider.rb +8 -0
- data/lib/orcid/version.rb +1 -1
- data/lib/orcid.rb +4 -0
- data/spec/controllers/orcid/profile_requests_controller_spec.rb +21 -9
- data/spec/features/public_api_query_spec.rb +6 -0
- data/spec/fixtures/orcid-remote-profile_query_service-response_parser/multiple-responses-without-valid-response.json +258 -0
- data/spec/fixtures/orcid-remote-profile_query_service-response_parser/single-response-with-orcid-valid-profile.json +71 -0
- data/spec/lib/orcid/configuration/provider_spec.rb +3 -0
- data/spec/lib/orcid_spec.rb +8 -0
- data/spec/models/orcid/profile_connection_spec.rb +39 -17
- data/spec/models/orcid/profile_status_spec.rb +73 -0
- data/spec/routing/orcid/profile_request_routing_spec.rb +15 -0
- data/spec/services/orcid/remote/profile_creation_service_spec.rb +23 -3
- data/spec/services/orcid/remote/profile_query_service/response_parser_spec.rb +43 -0
- data/spec/services/orcid/remote/profile_query_service_spec.rb +7 -89
- data/spec/views/orcid/profile_connections/_authenticated_connection.html.erb_spec.rb +20 -0
- data/spec/views/orcid/profile_connections/_options_to_connect_orcid_profile.html.erb_spec.rb +26 -0
- data/spec/views/orcid/profile_connections/_orcid_connector.html.erb_spec.rb +65 -0
- data/spec/views/orcid/profile_connections/_pending_connection.html.erb_spec.rb +22 -0
- data/spec/views/orcid/profile_connections/_profile_request_pending.html.erb_spec.rb +24 -0
- metadata +29 -2
@@ -11,30 +11,50 @@ module Orcid::Remote
|
|
11
11
|
{ 'Content-Type' => 'application/vdn.orcid+xml', 'Accept' => 'application/xml' }
|
12
12
|
}
|
13
13
|
Given(:callback) { StubCallback.new }
|
14
|
-
Given(:callback_config) { callback.configure }
|
14
|
+
Given(:callback_config) { callback.configure(:orcid_validation_error) }
|
15
15
|
|
16
16
|
Given(:response) {
|
17
17
|
double("Response", headers: { location: File.join("/", minted_orcid, "orcid-profile") })
|
18
18
|
}
|
19
19
|
|
20
|
-
When(:returned_value) { described_class.call(payload, config, &callback_config) }
|
21
20
|
|
22
21
|
context 'with orcid created' do
|
23
22
|
Given(:response) {
|
24
23
|
double("Response", headers: { location: File.join("/", minted_orcid, "orcid-profile") })
|
25
24
|
}
|
25
|
+
When(:returned_value) { described_class.call(payload, config, &callback_config) }
|
26
26
|
Then { returned_value.should eq(minted_orcid)}
|
27
27
|
And { expect(callback.invoked).to eq [:success, minted_orcid] }
|
28
28
|
And { token.should have_received(:post).with(config.fetch(:path), body: payload, headers: request_headers)}
|
29
29
|
end
|
30
30
|
|
31
|
-
context 'with orcid created' do
|
31
|
+
context 'with orcid not created' do
|
32
32
|
Given(:response) {
|
33
33
|
double("Response", headers: { location: "" })
|
34
34
|
}
|
35
|
+
When(:returned_value) { described_class.call(payload, config, &callback_config) }
|
35
36
|
Then { returned_value.should eq(false)}
|
36
37
|
And { expect(callback.invoked).to eq [:failure] }
|
37
38
|
And { token.should have_received(:post).with(config.fetch(:path), body: payload, headers: request_headers)}
|
38
39
|
end
|
40
|
+
|
41
|
+
context 'with an orcid validation error' do
|
42
|
+
before { token.should_receive(:post).and_raise(error) }
|
43
|
+
Given(:token) { double('Token') }
|
44
|
+
Given(:error_description) { 'My special error' }
|
45
|
+
Given(:response) do
|
46
|
+
double(
|
47
|
+
'Response',
|
48
|
+
:body => "<error-desc>#{error_description}</error-desc>",
|
49
|
+
:parsed => true,
|
50
|
+
:error= => true
|
51
|
+
)
|
52
|
+
end
|
53
|
+
Given(:error) { ::OAuth2::Error.new(response) }
|
54
|
+
When(:returned_value) { described_class.call(payload, config, &callback_config) }
|
55
|
+
Then { returned_value.should eq(false) }
|
56
|
+
And { expect(callback.invoked).to eq [:orcid_validation_error, error_description] }
|
57
|
+
end
|
58
|
+
|
39
59
|
end
|
40
60
|
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
require 'ostruct'
|
2
|
+
require 'spec_helper'
|
3
|
+
require 'orcid/remote/profile_query_service/response_parser'
|
4
|
+
|
5
|
+
module Orcid
|
6
|
+
module Remote
|
7
|
+
class ProfileQueryService
|
8
|
+
describe ResponseParser do
|
9
|
+
context '.call' do
|
10
|
+
Given(:response_builder) { OpenStruct }
|
11
|
+
Given(:logger) { double(warn: true) }
|
12
|
+
Given(:document) do
|
13
|
+
File.read(fixture_file(File.join('orcid-remote-profile_query_service-response_parser',response_filename)))
|
14
|
+
end
|
15
|
+
Given(:subject) { described_class.new(response_builder: response_builder, logger: logger) }
|
16
|
+
|
17
|
+
context 'happy path' do
|
18
|
+
let(:response_filename) { 'single-response-with-orcid-valid-profile.json' }
|
19
|
+
When(:response) { subject.call(document) }
|
20
|
+
Then do
|
21
|
+
response.should eq(
|
22
|
+
[
|
23
|
+
response_builder.new(
|
24
|
+
id: "MY-ORCID-PROFILE-ID",
|
25
|
+
label: "Corwin Amber (MY-ORCID-EMAIL) [ORCID: MY-ORCID-PROFILE-ID]",
|
26
|
+
biography:"MY-ORCID-BIOGRAPHY"
|
27
|
+
)
|
28
|
+
]
|
29
|
+
)
|
30
|
+
end
|
31
|
+
end
|
32
|
+
|
33
|
+
context 'unhappy path' do
|
34
|
+
let(:response_filename) { 'multiple-responses-without-valid-response.json' }
|
35
|
+
When(:response) { subject.call(document) }
|
36
|
+
Then { response.should eq [] }
|
37
|
+
And { logger.should have_received(:warn).at_least(1).times }
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
@@ -4,30 +4,24 @@ require 'ostruct'
|
|
4
4
|
|
5
5
|
module Orcid::Remote
|
6
6
|
describe ProfileQueryService do
|
7
|
-
Given(:
|
8
|
-
Given(:biography) { 'King of Amber' }
|
9
|
-
Given(:orcid_profile_id) { '0001-0002' }
|
7
|
+
Given(:parser) { double('Parser', call: parsed_response)}
|
10
8
|
Given(:config) {
|
11
9
|
{
|
12
10
|
token: token,
|
13
11
|
path: 'somehwere',
|
14
12
|
headers: 'headers',
|
15
|
-
|
13
|
+
parser: parser,
|
16
14
|
query_parameter_builder: query_parameter_builder
|
17
15
|
}
|
18
16
|
}
|
19
|
-
Given(:query_parameter_builder) { double('Query Builder')}
|
20
|
-
Given(:response) { double("Response", body:
|
17
|
+
Given(:query_parameter_builder) { double('Query Builder') }
|
18
|
+
Given(:response) { double("Response", body: 'Response Body') }
|
21
19
|
Given(:token) { double("Token") }
|
22
|
-
Given(:json_response) {
|
23
|
-
[
|
24
|
-
OpenStruct.new({ 'id' => orcid_profile_id, 'label' => "Corwin Amber (#{email}) [ORCID: #{orcid_profile_id}]", 'biography' => biography })
|
25
|
-
]
|
26
|
-
}
|
27
20
|
Given(:parameters) { double("Parameters") }
|
28
21
|
Given(:normalized_parameters) { double("Normalized Parameters") }
|
29
22
|
Given(:callback) { StubCallback.new }
|
30
23
|
Given(:callback_config) { callback.configure(:found, :not_found) }
|
24
|
+
Given(:parsed_response) { 'HELLO WORLD!' }
|
31
25
|
|
32
26
|
context '.call' do
|
33
27
|
before(:each) do
|
@@ -35,84 +29,8 @@ module Orcid::Remote
|
|
35
29
|
token.should_receive(:get).with(config[:path], headers: config[:headers], params: normalized_parameters).and_return(response)
|
36
30
|
end
|
37
31
|
When(:result) { described_class.call(parameters, config, &callback_config) }
|
38
|
-
Then { expect(result).to eq(
|
39
|
-
And { expect(callback.invoked).to eq [:found,
|
32
|
+
Then { expect(result).to eq(parsed_response) }
|
33
|
+
And { expect(callback.invoked).to eq [:found, parsed_response] }
|
40
34
|
end
|
41
|
-
|
42
|
-
Given(:response_body) {
|
43
|
-
%(
|
44
|
-
{
|
45
|
-
"message-version": "1.1",
|
46
|
-
"orcid-search-results": {
|
47
|
-
"orcid-search-result": [
|
48
|
-
{
|
49
|
-
"relevancy-score": {
|
50
|
-
"value": 14.298138
|
51
|
-
},
|
52
|
-
"orcid-profile": {
|
53
|
-
"orcid": null,
|
54
|
-
"orcid-identifier": {
|
55
|
-
"value": null,
|
56
|
-
"uri": "http://orcid.org/#{orcid_profile_id}",
|
57
|
-
"path": "#{orcid_profile_id}",
|
58
|
-
"host": "orcid.org"
|
59
|
-
},
|
60
|
-
"orcid-bio": {
|
61
|
-
"personal-details": {
|
62
|
-
"given-names": {
|
63
|
-
"value": "Corwin"
|
64
|
-
},
|
65
|
-
"family-name": {
|
66
|
-
"value": "Amber"
|
67
|
-
}
|
68
|
-
},
|
69
|
-
"biography": {
|
70
|
-
"value": "#{biography}",
|
71
|
-
"visibility": null
|
72
|
-
},
|
73
|
-
"contact-details": {
|
74
|
-
"email": [
|
75
|
-
{
|
76
|
-
"value": "#{email}",
|
77
|
-
"primary": true,
|
78
|
-
"current": true,
|
79
|
-
"verified": true,
|
80
|
-
"visibility": null,
|
81
|
-
"source": null
|
82
|
-
}
|
83
|
-
],
|
84
|
-
"address": {
|
85
|
-
"country": {
|
86
|
-
"value": "US",
|
87
|
-
"visibility": null
|
88
|
-
}
|
89
|
-
}
|
90
|
-
},
|
91
|
-
"keywords": {
|
92
|
-
"keyword": [
|
93
|
-
{
|
94
|
-
"value": "Lord of Amber"
|
95
|
-
}
|
96
|
-
],
|
97
|
-
"visibility": null
|
98
|
-
},
|
99
|
-
"delegation": null,
|
100
|
-
"applications": null,
|
101
|
-
"scope": null
|
102
|
-
},
|
103
|
-
"orcid-activities": {
|
104
|
-
"affiliations": null
|
105
|
-
},
|
106
|
-
"type": null,
|
107
|
-
"group-type": null,
|
108
|
-
"client-type": null
|
109
|
-
}
|
110
|
-
}
|
111
|
-
],
|
112
|
-
"num-found": 1
|
113
|
-
}
|
114
|
-
}
|
115
|
-
)
|
116
|
-
}
|
117
35
|
end
|
118
36
|
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe 'orcid/profile_connections/_authenticated_connection.html.erb' do
|
4
|
+
Given(:profile) { double('Profile', orcid_profile_id: orcid_profile_id) }
|
5
|
+
Given(:orcid_profile_id) { '123-456' }
|
6
|
+
|
7
|
+
When(:rendered) do
|
8
|
+
render(
|
9
|
+
partial: 'orcid/profile_connections/authenticated_connection',
|
10
|
+
object: profile
|
11
|
+
)
|
12
|
+
end
|
13
|
+
|
14
|
+
Then do
|
15
|
+
expect(rendered).to have_tag('.authenticated-connection') do
|
16
|
+
with_tag('a.orcid-profile-id', text: orcid_profile_id)
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe 'orcid/profile_connections/_options_to_connect_orcid_profile.html.erb' do
|
4
|
+
let(:default_search_text) { '' }
|
5
|
+
it 'renders a form' do
|
6
|
+
render
|
7
|
+
expect(rendered).to(
|
8
|
+
have_tag('.options-to-connect-orcid-profile') do
|
9
|
+
with_tag(
|
10
|
+
'a',
|
11
|
+
with: { href: orcid.new_profile_connection_path(profile_connection: { text: default_search_text }) },
|
12
|
+
text: t('orcid/profile_connection.look_up_your_existing_orcid', scope: 'helpers.label')
|
13
|
+
)
|
14
|
+
with_tag(
|
15
|
+
'a',
|
16
|
+
with: { href: orcid.new_profile_request_path },
|
17
|
+
text: t('orcid/profile_connection.create_an_orcid', scope: 'helpers.label')
|
18
|
+
)
|
19
|
+
with_tag('form', with: { method: 'post', action: orcid.profile_connections_path }) do
|
20
|
+
with_tag('label', text: t('orcid/profile_connection.orcid_profile_id', scope: 'helpers.label'))
|
21
|
+
with_tag('input', with: { type: 'text', name: 'profile_connection[orcid_profile_id]' })
|
22
|
+
end
|
23
|
+
end
|
24
|
+
)
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,65 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe 'orcid/profile_connections/_orcid_connector.html.erb' do
|
4
|
+
let(:default_search_text) { 'hello' }
|
5
|
+
let(:current_user) { double('User') }
|
6
|
+
let(:status_processor) { double('Processor') }
|
7
|
+
let(:handler) do
|
8
|
+
double(
|
9
|
+
'Handler',
|
10
|
+
profile_request_pending: true,
|
11
|
+
unknown: true,
|
12
|
+
authenticated_connection: true,
|
13
|
+
pending_connection: true
|
14
|
+
)
|
15
|
+
end
|
16
|
+
def render_with_params
|
17
|
+
render(
|
18
|
+
partial: 'orcid/profile_connections/orcid_connector',
|
19
|
+
locals: { default_search_text: default_search_text, status_processor: status_processor, current_user: current_user }
|
20
|
+
)
|
21
|
+
end
|
22
|
+
|
23
|
+
before do
|
24
|
+
status_processor.should_receive(:call).with(current_user).and_yield(handler)
|
25
|
+
end
|
26
|
+
context 'with :unknown status' do
|
27
|
+
it 'renders the options to connect orcid profile' do
|
28
|
+
expect(handler).to receive(:unknown).and_yield
|
29
|
+
render_with_params
|
30
|
+
|
31
|
+
expect(view).to render_template(partial: 'orcid/profile_connections/_options_to_connect_orcid_profile')
|
32
|
+
expect(rendered).to have_tag('.orcid-connector')
|
33
|
+
end
|
34
|
+
end
|
35
|
+
context 'with :profile_request_pending status' do
|
36
|
+
let(:pending_request) { double('Pending Request', created_at: Time.now) }
|
37
|
+
it 'renders the options to view the pending profile request' do
|
38
|
+
expect(handler).to receive(:profile_request_pending).and_yield(pending_request)
|
39
|
+
render_with_params
|
40
|
+
|
41
|
+
expect(view).to render_template(partial: 'orcid/profile_connections/_profile_request_pending')
|
42
|
+
expect(rendered).to have_tag('.orcid-connector')
|
43
|
+
end
|
44
|
+
end
|
45
|
+
context 'with :authenticated_connection status' do
|
46
|
+
let(:profile) { double('Profile', orcid_profile_id: '123-456') }
|
47
|
+
it 'renders the options to view the authenticated connection' do
|
48
|
+
expect(handler).to receive(:authenticated_connection).and_yield(profile)
|
49
|
+
render_with_params
|
50
|
+
|
51
|
+
expect(view).to render_template(partial: 'orcid/profile_connections/_authenticated_connection')
|
52
|
+
expect(rendered).to have_tag('.orcid-connector')
|
53
|
+
end
|
54
|
+
end
|
55
|
+
context 'with :pending_connection status' do
|
56
|
+
let(:profile) { double('Profile', orcid_profile_id: '123-456') }
|
57
|
+
it 'renders the options to view the authenticated connection' do
|
58
|
+
expect(handler).to receive(:pending_connection).and_yield(profile)
|
59
|
+
render_with_params
|
60
|
+
|
61
|
+
expect(view).to render_template(partial: 'orcid/profile_connections/_pending_connection')
|
62
|
+
expect(rendered).to have_tag('.orcid-connector')
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe 'orcid/profile_connections/_pending_connection.html.erb' do
|
4
|
+
Given(:profile) { double('Profile', orcid_profile_id: orcid_profile_id) }
|
5
|
+
Given(:orcid_profile_id) { '123-456' }
|
6
|
+
|
7
|
+
When(:rendered) do
|
8
|
+
render(
|
9
|
+
partial: 'orcid/profile_connections/pending_connection',
|
10
|
+
object: profile
|
11
|
+
)
|
12
|
+
end
|
13
|
+
|
14
|
+
Then do
|
15
|
+
expect(rendered).to have_tag('.pending-connection') do
|
16
|
+
with_tag('a.orcid-profile-id', text: orcid_profile_id)
|
17
|
+
with_tag('a.find-out-more')
|
18
|
+
with_tag('a.signin-via-orcid')
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
22
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe 'orcid/profile_connections/_profile_request_pending.html.erb' do
|
4
|
+
Given(:profile_request) { double('ProfileRequest', created_at: created_at) }
|
5
|
+
Given(:created_at) { Date.today }
|
6
|
+
|
7
|
+
When(:rendered) do
|
8
|
+
render(
|
9
|
+
partial: 'orcid/profile_connections/profile_request_pending',
|
10
|
+
object: profile_request
|
11
|
+
)
|
12
|
+
end
|
13
|
+
|
14
|
+
Then do
|
15
|
+
expect(rendered).to have_tag('.profile-request-pending') do
|
16
|
+
with_tag(
|
17
|
+
'time',
|
18
|
+
with: { datetime: created_at.in_time_zone.to_s },
|
19
|
+
text: view.time_ago_in_words(created_at)
|
20
|
+
)
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: orcid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeremy Friesen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
11
|
+
date: 2014-05-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -300,6 +300,7 @@ files:
|
|
300
300
|
- .gitignore
|
301
301
|
- .hound.yml
|
302
302
|
- .travis.yml
|
303
|
+
- CONTRIBUTING.md
|
303
304
|
- Gemfile
|
304
305
|
- LICENSE
|
305
306
|
- README.md
|
@@ -313,6 +314,7 @@ files:
|
|
313
314
|
- app/models/orcid/profile.rb
|
314
315
|
- app/models/orcid/profile_connection.rb
|
315
316
|
- app/models/orcid/profile_request.rb
|
317
|
+
- app/models/orcid/profile_status.rb
|
316
318
|
- app/models/orcid/work.rb
|
317
319
|
- app/models/orcid/work/xml_parser.rb
|
318
320
|
- app/models/orcid/work/xml_renderer.rb
|
@@ -320,12 +322,17 @@ files:
|
|
320
322
|
- app/services/orcid/remote/profile_creation_service.rb
|
321
323
|
- app/services/orcid/remote/profile_query_service.rb
|
322
324
|
- app/services/orcid/remote/profile_query_service/query_parameter_builder.rb
|
325
|
+
- app/services/orcid/remote/profile_query_service/response_parser.rb
|
323
326
|
- app/services/orcid/remote/profile_query_service/search_response.rb
|
324
327
|
- app/services/orcid/remote/service.rb
|
325
328
|
- app/services/orcid/remote/work_service.rb
|
326
329
|
- app/templates/orcid/work.template.v1.1.xml.erb
|
327
330
|
- app/views/layouts/orcid/application.html.erb
|
331
|
+
- app/views/orcid/profile_connections/_authenticated_connection.html.erb
|
332
|
+
- app/views/orcid/profile_connections/_options_to_connect_orcid_profile.html.erb
|
328
333
|
- app/views/orcid/profile_connections/_orcid_connector.html.erb
|
334
|
+
- app/views/orcid/profile_connections/_pending_connection.html.erb
|
335
|
+
- app/views/orcid/profile_connections/_profile_request_pending.html.erb
|
329
336
|
- app/views/orcid/profile_connections/new.html.erb
|
330
337
|
- app/views/orcid/profile_requests/new.html.erb
|
331
338
|
- app/views/orcid/profile_requests/show.html.erb
|
@@ -357,6 +364,8 @@ files:
|
|
357
364
|
- spec/features/non_ui_based_interactions_spec.rb
|
358
365
|
- spec/features/profile_connection_feature_spec.rb
|
359
366
|
- spec/features/public_api_query_spec.rb
|
367
|
+
- spec/fixtures/orcid-remote-profile_query_service-response_parser/multiple-responses-without-valid-response.json
|
368
|
+
- spec/fixtures/orcid-remote-profile_query_service-response_parser/single-response-with-orcid-valid-profile.json
|
360
369
|
- spec/fixtures/orcid_works.xml
|
361
370
|
- spec/lib/orcid/configuration/provider_spec.rb
|
362
371
|
- spec/lib/orcid/configuration_spec.rb
|
@@ -365,11 +374,14 @@ files:
|
|
365
374
|
- spec/models/orcid/profile_connection_spec.rb
|
366
375
|
- spec/models/orcid/profile_request_spec.rb
|
367
376
|
- spec/models/orcid/profile_spec.rb
|
377
|
+
- spec/models/orcid/profile_status_spec.rb
|
368
378
|
- spec/models/orcid/work/xml_parser_spec.rb
|
369
379
|
- spec/models/orcid/work/xml_renderer_spec.rb
|
370
380
|
- spec/models/orcid/work_spec.rb
|
381
|
+
- spec/routing/orcid/profile_request_routing_spec.rb
|
371
382
|
- spec/services/orcid/remote/profile_creation_service_spec.rb
|
372
383
|
- spec/services/orcid/remote/profile_query_service/query_parameter_builder_spec.rb
|
384
|
+
- spec/services/orcid/remote/profile_query_service/response_parser_spec.rb
|
373
385
|
- spec/services/orcid/remote/profile_query_service/search_response_spec.rb
|
374
386
|
- spec/services/orcid/remote/profile_query_service_spec.rb
|
375
387
|
- spec/services/orcid/remote/service_spec.rb
|
@@ -379,6 +391,11 @@ files:
|
|
379
391
|
- spec/support/stub_callback.rb
|
380
392
|
- spec/test_app_templates/Gemfile.extra
|
381
393
|
- spec/test_app_templates/lib/generators/test_app_generator.rb
|
394
|
+
- spec/views/orcid/profile_connections/_authenticated_connection.html.erb_spec.rb
|
395
|
+
- spec/views/orcid/profile_connections/_options_to_connect_orcid_profile.html.erb_spec.rb
|
396
|
+
- spec/views/orcid/profile_connections/_orcid_connector.html.erb_spec.rb
|
397
|
+
- spec/views/orcid/profile_connections/_pending_connection.html.erb_spec.rb
|
398
|
+
- spec/views/orcid/profile_connections/_profile_request_pending.html.erb_spec.rb
|
382
399
|
- spec/views/orcid/profile_connections/new.html.erb_spec.rb
|
383
400
|
- spec/views/orcid/profile_requests/new.html.erb_spec.rb
|
384
401
|
homepage: https://github.com/jeremyf/orcid
|
@@ -414,6 +431,8 @@ test_files:
|
|
414
431
|
- spec/features/non_ui_based_interactions_spec.rb
|
415
432
|
- spec/features/profile_connection_feature_spec.rb
|
416
433
|
- spec/features/public_api_query_spec.rb
|
434
|
+
- spec/fixtures/orcid-remote-profile_query_service-response_parser/multiple-responses-without-valid-response.json
|
435
|
+
- spec/fixtures/orcid-remote-profile_query_service-response_parser/single-response-with-orcid-valid-profile.json
|
417
436
|
- spec/fixtures/orcid_works.xml
|
418
437
|
- spec/lib/orcid/configuration/provider_spec.rb
|
419
438
|
- spec/lib/orcid/configuration_spec.rb
|
@@ -422,11 +441,14 @@ test_files:
|
|
422
441
|
- spec/models/orcid/profile_connection_spec.rb
|
423
442
|
- spec/models/orcid/profile_request_spec.rb
|
424
443
|
- spec/models/orcid/profile_spec.rb
|
444
|
+
- spec/models/orcid/profile_status_spec.rb
|
425
445
|
- spec/models/orcid/work/xml_parser_spec.rb
|
426
446
|
- spec/models/orcid/work/xml_renderer_spec.rb
|
427
447
|
- spec/models/orcid/work_spec.rb
|
448
|
+
- spec/routing/orcid/profile_request_routing_spec.rb
|
428
449
|
- spec/services/orcid/remote/profile_creation_service_spec.rb
|
429
450
|
- spec/services/orcid/remote/profile_query_service/query_parameter_builder_spec.rb
|
451
|
+
- spec/services/orcid/remote/profile_query_service/response_parser_spec.rb
|
430
452
|
- spec/services/orcid/remote/profile_query_service/search_response_spec.rb
|
431
453
|
- spec/services/orcid/remote/profile_query_service_spec.rb
|
432
454
|
- spec/services/orcid/remote/service_spec.rb
|
@@ -436,5 +458,10 @@ test_files:
|
|
436
458
|
- spec/support/stub_callback.rb
|
437
459
|
- spec/test_app_templates/Gemfile.extra
|
438
460
|
- spec/test_app_templates/lib/generators/test_app_generator.rb
|
461
|
+
- spec/views/orcid/profile_connections/_authenticated_connection.html.erb_spec.rb
|
462
|
+
- spec/views/orcid/profile_connections/_options_to_connect_orcid_profile.html.erb_spec.rb
|
463
|
+
- spec/views/orcid/profile_connections/_orcid_connector.html.erb_spec.rb
|
464
|
+
- spec/views/orcid/profile_connections/_pending_connection.html.erb_spec.rb
|
465
|
+
- spec/views/orcid/profile_connections/_profile_request_pending.html.erb_spec.rb
|
439
466
|
- spec/views/orcid/profile_connections/new.html.erb_spec.rb
|
440
467
|
- spec/views/orcid/profile_requests/new.html.erb_spec.rb
|