Skip to content

Commit c2b74bd

Browse files
author
markwilkinson
committed
brig test back to life
1 parent 4e0407a commit c2b74bd

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

app/tests/fc_metadata_identifier_in_metadata.rb

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def self.fc_metadata_identifier_in_metadata_meta
1616
responsible_developer: 'Mark D Wilkinson',
1717
email: 'mark.wilkinson@upm.es',
1818
response_description: 'The response is "pass", "fail" or "indeterminate"',
19-
schemas: { 'subject' => ['string', 'the GUID being tested'] },
19+
schemas: { 'resource_identifier' => ['string', 'the GUID being tested'] },
2020
organizations: [{ 'name' => 'OSTrails Project', 'url' => 'https://ostrails.eu/' }],
2121
individuals: [{ 'name' => 'Mark D Wilkinson', 'email' => 'mark.wilkinson@upm.es' }],
2222
creator: 'https://orcid.org/0000-0001-6960-357X',
@@ -27,16 +27,16 @@ def self.fc_metadata_identifier_in_metadata_meta
2727
end
2828

2929
def self.fc_metadata_identifier_in_metadata(guid:)
30-
FAIRChampion::Output.clear_comments
30+
FtrRuby::Output.clear_comments
3131

32-
output = FAIRChampion::Output.new(
32+
output = FtrRuby::Output.new(
3333
testedGUID: guid,
3434
meta: fc_metadata_identifier_in_metadata_meta
3535
)
3636

3737
output.comments << "INFO: TEST VERSION '#{fc_metadata_identifier_in_metadata_meta[:testversion]}'\n"
3838

39-
metadata = FAIRChampion::Harvester.resolveit(guid) # this is where the magic happens!
39+
metadata = FAIRChampionHarvester::Core.resolveit(guid) # this is where the magic happens!
4040

4141
metadata.comments.each do |c|
4242
output.comments << c
@@ -57,9 +57,9 @@ def self.fc_metadata_identifier_in_metadata(guid:)
5757
#############################################################################################################
5858

5959
if graph.size > 0
60-
output.comments << "INFO: Linked Data Found. Now searching for the metadata identifier using appropriate linked data predicates (#{FAIRChampion::Utils::SELF_IDENTIFIER_PREDICATES}).\n"
60+
output.comments << "INFO: Linked Data Found. Now searching for the metadata identifier using appropriate linked data predicates (#{FAIRChampionHarvester::Utils::SELF_IDENTIFIER_PREDICATES}).\n"
6161

62-
foundID = FAIRChampion::CommonQueries::GetSelfIdentifier(metadata.graph, output)
62+
foundID = FAIRChampionHarvester::CommonQueries::GetSelfIdentifier(metadata.graph, output)
6363

6464
# query pattern-match in an object position
6565
unless foundID.first
@@ -69,12 +69,12 @@ def self.fc_metadata_identifier_in_metadata(guid:)
6969
end
7070
if foundID.first.empty?
7171
output.score = 'fail'
72-
output.comments << "FAILURE: No metadata identifiers were found in the metadata record using predicates #{FAIRChampion::Utils::SELF_IDENTIFIER_PREDICATES}. \n"
72+
output.comments << "FAILURE: No metadata identifiers were found in the metadata record using predicates #{FAIRChampionHarvester::Utils::SELF_IDENTIFIER_PREDICATES}. \n"
7373
return output.createEvaluationResponse # release the result from all other tests
7474
end
7575
unless foundID.first =~ /\w/
7676
output.score = 'fail'
77-
output.comments << "FAILURE: No metadata identifiers were found in the metadata record using predicates #{FAIRChampion::Utils::SELF_IDENTIFIER_PREDICATES}. \n"
77+
output.comments << "FAILURE: No metadata identifiers were found in the metadata record using predicates #{FAIRChampionHarvester::Utils::SELF_IDENTIFIER_PREDICATES}. \n"
7878
return output.createEvaluationResponse # release the result from all other tests
7979
end
8080

@@ -96,12 +96,12 @@ def self.fc_metadata_identifier_in_metadata(guid:)
9696
end
9797

9898
def self.fc_metadata_identifier_in_metadata_api
99-
api = OpenAPI.new(meta: fc_metadata_identifier_in_metadata_meta)
99+
api = FtrRuby::OpenAPI.new(meta: fc_metadata_identifier_in_metadata_meta)
100100
api.get_api
101101
end
102102

103103
def self.fc_metadata_identifier_in_metadata_about
104-
dcat = ChampionDCAT::DCAT_Record.new(meta: fc_metadata_identifier_in_metadata_meta)
104+
dcat = FtrRuby::DCAT_Record.new(meta: fc_metadata_identifier_in_metadata_meta)
105105
dcat.get_dcat
106106
end
107107
end

0 commit comments

Comments
 (0)