Skip to content

Commit

Permalink
Fix #45
Browse files Browse the repository at this point in the history
  • Loading branch information
michielbdejong committed Mar 5, 2021
1 parent 2c420f4 commit e3f44bc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
4 changes: 2 additions & 2 deletions test/surface/create-non-container.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ describe("Create non-container", () => {
method: "PATCH",
body: "INSERT DATA { <#hello> <#linked> <#world> . }",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
});
// console.log(result);
Expand Down Expand Up @@ -352,7 +352,7 @@ describe("Create non-container", () => {
method: "PATCH",
body: "INSERT DATA { <#hello> <#linked> <#world> . }",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
});
await new Promise((resolve) => setTimeout(resolve, 2000));
Expand Down
15 changes: 7 additions & 8 deletions test/surface/update.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body: "INSERT DATA { <#that> a <#fact> . }",
});
Expand Down Expand Up @@ -305,7 +305,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body:
"DELETE DATA { <#hello> <#linked> <#world> . };\nINSERT DATA { <#hello> <#linked> <#world> . }",
Expand Down Expand Up @@ -366,7 +366,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body:
"DELETE DATA { <#hello> <#linked> <#world> . };\nINSERT DATA { <#that> a <#fact> . }",
Expand Down Expand Up @@ -404,8 +404,7 @@ describe("Update", () => {
});
});

// DESIRED BEHAVIOUR UNDECIDED: see https://github.com/solid/solid-crud-tests/issues/45
describe.skip("Using PATCH to replace triple (not present)", () => {
describe("Using PATCH to replace triple (not present)", () => {
const { testFolderUrl } = generateTestFolder();
let websocketsPubsubClientResource;
const containerUrl = `${testFolderUrl}exists/`;
Expand All @@ -427,7 +426,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body:
"DELETE DATA { <#something> <#completely> <#different> . };\nINSERT DATA { <#that> a <#fact> . }",
Expand Down Expand Up @@ -490,7 +489,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body: "DELETE DATA { <#hello> <#linked> <#world> . }",
});
Expand Down Expand Up @@ -542,7 +541,7 @@ describe("Update", () => {
const result = await authFetcher.fetch(resourceUrl, {
method: "PATCH",
headers: {
"Content-Type": "application/sparql-update",
"Content-Type": "application/sparql-update-single-match",
},
body: "DELETE DATA { <#something> <#completely> <#different> . }",
});
Expand Down

0 comments on commit e3f44bc

Please sign in to comment.