Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- A group of generic query examples was added (#135).
- Some icons for well known query groups were added (#146).

## [1.2.2] - 2024-06-27

### Added
Expand Down
12 changes: 6 additions & 6 deletions cypress/e2e/custom-query-editor.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ PREFIX oo: <http://purl.org/openorg/>
PREFIX ao: <http://purl.org/ontology/ao/core#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX d: <http://www/example.com/data/>
PREFIX o: <http://www/example.com/ont/>
PREFIX d: <https://www.example.com/data/>
PREFIX o: <https://www.example.com/ont/>

SELECT DISTINCT ?component ?componentName ?recycledContentPercentage
WHERE {
Expand All @@ -60,7 +60,7 @@ ORDER BY ?componentName
cy.get('button[type="submit"]').click();

// Checking if the query works
cy.contains("http://www/example.com/data/component-c01").should('exist');
cy.contains("https://www.example.com/data/component-c01").should('exist');
});

it("Check if all possible parameters are filled in with parameterized URL", () => {
Expand Down Expand Up @@ -227,8 +227,8 @@ PREFIX oo: <http://purl.org/openorg/>
PREFIX ao: <http://purl.org/ontology/ao/core#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX d: <http://www/example.com/data/>
PREFIX o: <http://www/example.com/ont/>
PREFIX d: <https://www.example.com/data/>
PREFIX o: <https://www.example.com/ont/>

SELECT ?component ?componentName ?material ?materialName ?percentage
WHERE {
Expand Down Expand Up @@ -263,7 +263,7 @@ WHERE {
)
cy.get('button[type="submit"]').click();

cy.contains("http://www/example.com/data/component-c01").should('exist');
cy.contains("https://www.example.com/data/component-c01").should('exist');

})

Expand Down
10 changes: 6 additions & 4 deletions cypress/e2e/fetch-status.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ describe("Fetch Status", () => {
cy.get('input[name="idp"]').type("http://localhost:8080");
cy.contains("Login").click();

cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
cy.origin('http://localhost:8080', () => {
cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
});

cy.url().should("eq", "http://localhost:5173/");

Expand Down
22 changes: 13 additions & 9 deletions cypress/e2e/log-in.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,12 @@ describe("Log in", () => {
.type("http://localhost:8080/example/profile/card#me");
cy.contains("Login").click();

cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
cy.origin('http://localhost:8080', () => {
cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
});

cy.url().should("eq", "http://localhost:5173/");
});
Expand Down Expand Up @@ -74,11 +76,13 @@ describe("Log in", () => {
cy.get('input[name="idp"]').type("http://localhost:8080");
cy.contains("Login").click();

cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();

cy.origin('http://localhost:8080', () => {
cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
});

cy.url().should("eq", "http://localhost:5173/");

cy.contains("General examples").click();
Expand Down
22 changes: 12 additions & 10 deletions cypress/e2e/sources-from-indexfile.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe("Sources from index file", () => {
cy.get('.information-box').contains('Sources: 3');

// Check if correct data is displayed
cy.contains("http://www/example.com/data/component-c01");
cy.contains("https://www.example.com/data/component-c01");
cy.contains("Component 1");
cy.contains("Material 1");
});
Expand All @@ -33,7 +33,7 @@ describe("Sources from index file", () => {
cy.get('.information-box').contains('Sources: 4');

// Check if correct data is still displayed even if one source was unauthorized
cy.contains("http://www/example.com/data/component-c01");
cy.contains("https://www.example.com/data/component-c01");
cy.contains("Component 1");
cy.contains("Material 1");
});
Expand All @@ -52,7 +52,7 @@ describe("Sources from index file", () => {
cy.get('.information-box').contains('Sources: 4');

// Check if correct data is still displayed even if one source was unauthorized and different sources were merged
cy.contains("http://www/example.com/data/component-c01");
cy.contains("https://www.example.com/data/component-c01");
cy.contains("Component 1");
cy.contains("Material 1");
});
Expand All @@ -72,7 +72,7 @@ describe("Sources from index file", () => {
});


cy.contains("http://www/example.com/data/component-c01").should("not.exist");
cy.contains("https://www.example.com/data/component-c01").should("not.exist");
cy.contains("Component 1").should("not.exist");
cy.contains("Material 1").should("not.exist");

Expand All @@ -86,18 +86,20 @@ describe("Sources from index file", () => {
.type("http://localhost:8080/example/profile/card#me");
cy.contains("Login").click();

cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();

cy.origin('http://localhost:8080', () => {
cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
});

cy.url().should("eq", "http://localhost:5173/");

//now try again
cy.contains("For testing only").click();
cy.contains("Sources from an index file (requiring authentication)").click();

cy.contains("http://www/example.com/data/component-c01").should("not.exist");
cy.contains("https://www.example.com/data/component-c01").should("not.exist");
cy.contains("Component 1").should("exist");
cy.contains("Material 1").should("exist");
})
Expand Down
10 changes: 6 additions & 4 deletions cypress/e2e/sources-info.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,12 @@ describe("Sources info", () => {
cy.get('input[name="idp"]').type("http://localhost:8080");
cy.contains("Login").click();

cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
cy.origin('http://localhost:8080', () => {
cy.get("input#email").type("hello@example.com");
cy.get("input#password").type("abc123");
cy.contains("button", "Log in").click();
cy.contains("button", "Authorize").click();
});

cy.url().should("eq", "http://localhost:5173/");

Expand Down
114 changes: 57 additions & 57 deletions initial-pod-data/boms$.ttl
Original file line number Diff line number Diff line change
@@ -1,58 +1,58 @@

<http://www/example.com/data/component-bom-b01> a <http://www/example.com/ont/component-bom>;
<http://www/example.com/ont/has-component-material-assoc> <http://www/example.com/data/component-material-assoc-b01-m01>,
<http://www/example.com/data/component-material-assoc-b01-m02>, <http://www/example.com/data/component-material-assoc-b01-m03> .

<http://www/example.com/data/component-bom-b02> a <http://www/example.com/ont/component-bom>;
<http://www/example.com/ont/has-component-material-assoc> <http://www/example.com/data/component-material-assoc-b02-m04>,
<http://www/example.com/data/component-material-assoc-b02-m05>, <http://www/example.com/data/component-material-assoc-b02-m06>,
<http://www/example.com/data/component-material-assoc-b02-m07>, <http://www/example.com/data/component-material-assoc-b02-m08>,
<http://www/example.com/data/component-material-assoc-b02-m09> .

<http://www/example.com/data/component-bom-b03> a <http://www/example.com/ont/component-bom>;
<http://www/example.com/ont/has-component-material-assoc> <http://www/example.com/data/component-material-assoc-b03-m10>,
<http://www/example.com/data/component-material-assoc-b03-m11> .

<http://www/example.com/data/component-material-assoc-b01-m01> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m01>;
<http://www/example.com/ont/percentage> 60 .

<http://www/example.com/data/component-material-assoc-b01-m02> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m02>;
<http://www/example.com/ont/percentage> 30 .

<http://www/example.com/data/component-material-assoc-b01-m03> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m03>;
<http://www/example.com/ont/percentage> 10 .

<http://www/example.com/data/component-material-assoc-b02-m04> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m04>;
<http://www/example.com/ont/percentage> 40 .

<http://www/example.com/data/component-material-assoc-b02-m05> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m05>;
<http://www/example.com/ont/percentage> 20 .

<http://www/example.com/data/component-material-assoc-b02-m06> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m06>;
<http://www/example.com/ont/percentage> 25 .

<http://www/example.com/data/component-material-assoc-b02-m07> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m07>;
<http://www/example.com/ont/percentage> 7 .

<http://www/example.com/data/component-material-assoc-b02-m08> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m08>;
<http://www/example.com/ont/percentage> 5 .

<http://www/example.com/data/component-material-assoc-b02-m09> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m09>;
<http://www/example.com/ont/percentage> 3 .

<http://www/example.com/data/component-material-assoc-b03-m10> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m10>;
<http://www/example.com/ont/percentage> 85 .

<http://www/example.com/data/component-material-assoc-b03-m11> a <http://www/example.com/ont/component-material-assoc>;
<http://www/example.com/ont/has-material> <http://www/example.com/data/material-m11>;
<http://www/example.com/ont/percentage> 15 .
<https://www.example.com/data/component-bom-b01> a <https://www.example.com/ont/component-bom>;
<https://www.example.com/ont/has-component-material-assoc> <https://www.example.com/data/component-material-assoc-b01-m01>,
<https://www.example.com/data/component-material-assoc-b01-m02>, <https://www.example.com/data/component-material-assoc-b01-m03> .

<https://www.example.com/data/component-bom-b02> a <https://www.example.com/ont/component-bom>;
<https://www.example.com/ont/has-component-material-assoc> <https://www.example.com/data/component-material-assoc-b02-m04>,
<https://www.example.com/data/component-material-assoc-b02-m05>, <https://www.example.com/data/component-material-assoc-b02-m06>,
<https://www.example.com/data/component-material-assoc-b02-m07>, <https://www.example.com/data/component-material-assoc-b02-m08>,
<https://www.example.com/data/component-material-assoc-b02-m09> .

<https://www.example.com/data/component-bom-b03> a <https://www.example.com/ont/component-bom>;
<https://www.example.com/ont/has-component-material-assoc> <https://www.example.com/data/component-material-assoc-b03-m10>,
<https://www.example.com/data/component-material-assoc-b03-m11> .

<https://www.example.com/data/component-material-assoc-b01-m01> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m01>;
<https://www.example.com/ont/percentage> 60 .

<https://www.example.com/data/component-material-assoc-b01-m02> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m02>;
<https://www.example.com/ont/percentage> 30 .

<https://www.example.com/data/component-material-assoc-b01-m03> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m03>;
<https://www.example.com/ont/percentage> 10 .

<https://www.example.com/data/component-material-assoc-b02-m04> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m04>;
<https://www.example.com/ont/percentage> 40 .

<https://www.example.com/data/component-material-assoc-b02-m05> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m05>;
<https://www.example.com/ont/percentage> 20 .

<https://www.example.com/data/component-material-assoc-b02-m06> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m06>;
<https://www.example.com/ont/percentage> 25 .

<https://www.example.com/data/component-material-assoc-b02-m07> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m07>;
<https://www.example.com/ont/percentage> 7 .

<https://www.example.com/data/component-material-assoc-b02-m08> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m08>;
<https://www.example.com/ont/percentage> 5 .

<https://www.example.com/data/component-material-assoc-b02-m09> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m09>;
<https://www.example.com/ont/percentage> 3 .

<https://www.example.com/data/component-material-assoc-b03-m10> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m10>;
<https://www.example.com/ont/percentage> 85 .

<https://www.example.com/data/component-material-assoc-b03-m11> a <https://www.example.com/ont/component-material-assoc>;
<https://www.example.com/ont/has-material> <https://www.example.com/data/material-m11>;
<https://www.example.com/ont/percentage> 15 .
24 changes: 12 additions & 12 deletions initial-pod-data/components$.ttl
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@

<http://www/example.com/data/component-c01> a <http://www/example.com/ont/Component>;
<http://www/example.com/ont/has-component-bom> <http://www/example.com/data/component-bom-b01>;
<http://www/example.com/ont/name> "Component 1";
<http://www/example.com/ont/recycled-content-percentage> 80 .
<https://www.example.com/data/component-c01> a <https://www.example.com/ont/Component>;
<https://www.example.com/ont/has-component-bom> <https://www.example.com/data/component-bom-b01>;
<https://www.example.com/ont/name> "Component 1";
<https://www.example.com/ont/recycled-content-percentage> 80 .

<http://www/example.com/data/component-c02> a <http://www/example.com/ont/Component>;
<http://www/example.com/ont/has-component-bom> <http://www/example.com/data/component-bom-b02>;
<http://www/example.com/ont/name> "Component 2";
<http://www/example.com/ont/recycled-content-percentage> 20 .
<https://www.example.com/data/component-c02> a <https://www.example.com/ont/Component>;
<https://www.example.com/ont/has-component-bom> <https://www.example.com/data/component-bom-b02>;
<https://www.example.com/ont/name> "Component 2";
<https://www.example.com/ont/recycled-content-percentage> 20 .

<http://www/example.com/data/component-c03> a <http://www/example.com/ont/Component>;
<http://www/example.com/ont/has-component-bom> <http://www/example.com/data/component-bom-b03>;
<http://www/example.com/ont/name> "Component 3";
<http://www/example.com/ont/recycled-content-percentage> 0 .
<https://www.example.com/data/component-c03> a <https://www.example.com/ont/Component>;
<https://www.example.com/ont/has-component-bom> <https://www.example.com/data/component-bom-b03>;
<https://www.example.com/ont/name> "Component 3";
<https://www.example.com/ont/recycled-content-percentage> 0 .
Loading