Commits

Rezart Vata authored 53851ba18ee
[CST-5270] Fix unit testing
No tags

src/app/shared/mocks/section-sherpa-policies.service.mock.ts

Modified
1 1 import {
2 2 WorkspaceitemSectionSherpaPoliciesObject
3 3 } from '../../core/submission/models/workspaceitem-section-sherpa-policies.model';
4 4
5 5 export const SherpaDataResponse = {
6 6 'id': 'sherpaPolicies',
7 7 'retrievalTime': '2022-04-20T09:44:39.870+00:00',
8 8 'sherpaResponse':
9 - {
10 - 'error': false,
11 - 'message': null,
12 - 'metadata': {
13 - 'id': 23803,
14 - 'uri': 'http://v2.sherpa.ac.uk/id/publication/23803',
15 - 'dateCreated': '2012-11-20 14:51:52',
16 - 'dateModified': '2020-03-06 11:25:54',
17 - 'inDOAJ': false,
18 - 'publiclyVisible': true
9 + {
10 + 'error': false,
11 + 'message': null,
12 + 'metadata': {
13 + 'id': 23803,
14 + 'uri': 'http://v2.sherpa.ac.uk/id/publication/23803',
15 + 'dateCreated': '2012-11-20 14:51:52',
16 + 'dateModified': '2020-03-06 11:25:54',
17 + 'inDOAJ': false,
18 + 'publiclyVisible': true
19 + },
20 + 'journals': [{
21 + 'titles': ['The Lancet', 'Lancet'],
22 + 'url': 'http://www.thelancet.com/journals/lancet/issue/current',
23 + 'issns': ['0140-6736', '1474-547X'],
24 + 'romeoPub': 'Elsevier: The Lancet',
25 + 'zetoPub': 'Elsevier: The Lancet',
26 + 'publisher': {
27 + 'name': 'Elsevier',
28 + 'relationshipType': null,
29 + 'country': null,
30 + 'uri': 'http://www.elsevier.com/',
31 + 'identifier': null,
32 + 'publicationCount': 0,
33 + 'paidAccessDescription': 'Open access',
34 + 'paidAccessUrl': 'https://www.elsevier.com/about/open-science/open-access'
19 35 },
20 - 'journals': [{
21 - 'titles': ['The Lancet', 'Lancet'],
22 - 'url': 'http://www.thelancet.com/journals/lancet/issue/current',
23 - 'issns': ['0140-6736', '1474-547X'],
24 - 'romeoPub': 'Elsevier: The Lancet',
25 - 'zetoPub': 'Elsevier: The Lancet',
26 - 'publisher': {
27 - 'name': 'Elsevier',
28 - 'relationshipType': null,
29 - 'country': null,
30 - 'uri': 'http://www.elsevier.com/',
31 - 'identifier': null,
32 - 'publicationCount': 0,
33 - 'paidAccessDescription': 'Open access',
34 - 'paidAccessUrl': 'https://www.elsevier.com/about/open-science/open-access'
35 - },
36 - 'publishers': [{
37 - 'name': 'Elsevier',
38 - 'relationshipType': null,
39 - 'country': null,
40 - 'uri': 'http://www.elsevier.com/',
41 - 'identifier': null,
42 - 'publicationCount': 0,
43 - 'paidAccessDescription': 'Open access',
44 - 'paidAccessUrl': 'https://www.elsevier.com/about/open-science/open-access'
45 - }],
46 - 'policies': [{
47 - 'id': 0,
48 - 'openAccessPermitted': false,
49 - 'uri': null,
50 - 'internalMoniker': 'Lancet',
51 - 'permittedVersions': [{
52 - 'articleVersion': 'submitted',
53 - 'option': 1,
54 - 'conditions': ['Upon publication publisher copyright and source must be acknowledged', 'Upon publication must link to publisher version'],
55 - 'prerequisites': [],
56 - 'locations': ['Author\'s Homepage', 'Preprint Repository'],
57 - 'licenses': [],
58 - 'embargo': null
59 - }, {
60 - 'articleVersion': 'accepted',
61 - 'option': 1,
62 - 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
63 - 'prerequisites': [],
64 - 'locations': ['Author\'s Homepage', 'Institutional Website'],
65 - 'licenses': ['CC BY-NC-ND'],
66 - 'embargo': null
67 - }, {
68 - 'articleVersion': 'accepted',
69 - 'option': 2,
70 - 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
71 - 'prerequisites': ['If Required by Funder'],
72 - 'locations': ['Non-Commercial Repository'],
73 - 'licenses': ['CC BY-NC-ND'],
74 - 'embargo': null
75 - }, {
76 - 'articleVersion': 'accepted',
77 - 'option': 3,
78 - 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
79 - 'prerequisites': [],
80 - 'locations': ['Non-Commercial Repository'],
81 - 'licenses': [],
82 - 'embargo': null
83 - }],
84 - 'urls': {
85 - 'http://download.thelancet.com/flatcontentassets/authors/lancet-information-for-authors.pdf': 'Guidelines for Authors',
86 - 'http://www.thelancet.com/journals/lancet/article/PIIS0140-6736%2813%2960720-5/fulltext': 'The Lancet journals welcome a new open access policy',
87 - 'http://www.thelancet.com/lancet-information-for-authors/after-publication': 'What happens after publication?',
88 - 'http://www.thelancet.com/lancet/information-for-authors/disclosure-of-results': 'Disclosure of results before publication',
89 - 'https://www.elsevier.com/__data/assets/pdf_file/0005/78476/external-embargo-list.pdf': 'Journal Embargo Period List',
90 - 'https://www.elsevier.com/__data/assets/pdf_file/0011/78473/UK-Embargo-Periods.pdf': 'Journal Embargo List for UK Authors'
91 - },
92 - 'openAccessProhibited': false,
93 - 'publicationCount': 0,
94 - 'preArchiving': 'can',
95 - 'postArchiving': 'can',
96 - 'pubArchiving': 'cannot'
36 + 'publishers': [{
37 + 'name': 'Elsevier',
38 + 'relationshipType': null,
39 + 'country': null,
40 + 'uri': 'http://www.elsevier.com/',
41 + 'identifier': null,
42 + 'publicationCount': 0,
43 + 'paidAccessDescription': 'Open access',
44 + 'paidAccessUrl': 'https://www.elsevier.com/about/open-science/open-access'
45 + }],
46 + 'policies': [{
47 + 'id': 0,
48 + 'openAccessPermitted': false,
49 + 'uri': null,
50 + 'internalMoniker': 'Lancet',
51 + 'permittedVersions': [{
52 + 'articleVersion': 'submitted',
53 + 'option': 1,
54 + 'conditions': ['Upon publication publisher copyright and source must be acknowledged', 'Upon publication must link to publisher version'],
55 + 'prerequisites': [],
56 + 'locations': ['Author\'s Homepage', 'Preprint Repository'],
57 + 'licenses': [],
58 + 'embargo': null
59 + }, {
60 + 'articleVersion': 'accepted',
61 + 'option': 1,
62 + 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
63 + 'prerequisites': [],
64 + 'locations': ['Author\'s Homepage', 'Institutional Website'],
65 + 'licenses': ['CC BY-NC-ND'],
66 + 'embargo': null
67 + }, {
68 + 'articleVersion': 'accepted',
69 + 'option': 2,
70 + 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
71 + 'prerequisites': ['If Required by Funder'],
72 + 'locations': ['Non-Commercial Repository'],
73 + 'licenses': ['CC BY-NC-ND'],
74 + 'embargo': { amount: 6, units: 'Months' }
75 + }, {
76 + 'articleVersion': 'accepted',
77 + 'option': 3,
78 + 'conditions': ['Publisher copyright and source must be acknowledged', 'Must link to publisher version'],
79 + 'prerequisites': [],
80 + 'locations': ['Non-Commercial Repository'],
81 + 'licenses': [],
82 + 'embargo': null
97 83 }],
98 - 'inDOAJ': false
99 - }]
100 - }
84 + 'urls': {
85 + 'http://download.thelancet.com/flatcontentassets/authors/lancet-information-for-authors.pdf': 'Guidelines for Authors',
86 + 'http://www.thelancet.com/journals/lancet/article/PIIS0140-6736%2813%2960720-5/fulltext': 'The Lancet journals welcome a new open access policy',
87 + 'http://www.thelancet.com/lancet-information-for-authors/after-publication': 'What happens after publication?',
88 + 'http://www.thelancet.com/lancet/information-for-authors/disclosure-of-results': 'Disclosure of results before publication',
89 + 'https://www.elsevier.com/__data/assets/pdf_file/0005/78476/external-embargo-list.pdf': 'Journal Embargo Period List',
90 + 'https://www.elsevier.com/__data/assets/pdf_file/0011/78473/UK-Embargo-Periods.pdf': 'Journal Embargo List for UK Authors'
91 + },
92 + 'openAccessProhibited': false,
93 + 'publicationCount': 0,
94 + 'preArchiving': 'can',
95 + 'postArchiving': 'can',
96 + 'pubArchiving': 'cannot'
97 + }],
98 + 'inDOAJ': false
99 + }]
100 + }
101 101 } as WorkspaceitemSectionSherpaPoliciesObject;

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut