From 08a63dacf4952c147d7988bb436e9f7da4513af0 Mon Sep 17 00:00:00 2001 From: mr7falcon Date: Sat, 4 May 2019 15:24:21 +0300 Subject: [PATCH] =?UTF-8?q?HTTP=20=D0=B7=D0=B0=D0=BF=D1=80=D0=BE=D1=81=20?= =?UTF-8?q?=D0=B2=D1=8B=D0=B4=D0=B0=D0=B5=D1=82=20=D1=81=D1=82=D0=B0=D1=82?= =?UTF-8?q?=D1=83=D1=81=20403.=20=D0=9B=D0=B8=D0=B1=D0=BE=20=D1=87=D1=82?= =?UTF-8?q?=D0=BE-=D1=82=D0=BE=20=D1=81=D0=BE=20=D0=BC=D0=BD=D0=BE=D0=B9?= =?UTF-8?q?=20=D0=BD=D0=B5=20=D1=82=D0=B0=D0=BA,=20=D0=BB=D0=B8=D0=B1?= =?UTF-8?q?=D0=BE=20=D1=83=20=D0=BC=D0=B5=D0=BD=D1=8F=20=D0=BD=D0=B5=D1=82?= =?UTF-8?q?=20=D1=80=D0=B0=D0=B7=D1=80=D0=B5=D1=88=D0=B5=D0=BD=D0=B8=D1=8F?= =?UTF-8?q?=20=D0=BD=D0=B0=20=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20=D1=82=D1=80=D0=B8=D0=BF=D0=BB=D0=BE=D0=B2?= =?UTF-8?q?...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/rdf4j-tests/transactions.test.js | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 src/rdf4j-tests/transactions.test.js diff --git a/src/rdf4j-tests/transactions.test.js b/src/rdf4j-tests/transactions.test.js new file mode 100644 index 000000000..a78231445 --- /dev/null +++ b/src/rdf4j-tests/transactions.test.js @@ -0,0 +1,22 @@ +const url = 'https://agentlab.ru/rdf4j-server/repositories/rpo-tests/transactions'; + +test('adding triples with PUT query and transactions', async () => { + const tID = await fetch(url, { + method: 'POST', + }).then((r) => r.headers.get('Location')); + + expect(tID).not.toBe(null); + + console.log(tID); + + const result = await fetch(tID + '?action=ADD', { + method: 'PUT', + headers: { + 'Content-Type': 'text/turtle', + }, + body: + ' .', + }).then((r) => r); + + console.log(result); +});