From 2020c3f77d405508aec745dc9466ab05f1c12789 Mon Sep 17 00:00:00 2001 From: Jesse Wright <63333554+jeswr@users.noreply.github.com> Date: Sun, 8 Sep 2024 22:43:10 +1000 Subject: [PATCH] chore: add mutation tests --- test/N3Store-test.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/N3Store-test.js b/test/N3Store-test.js index b458e94..2945687 100644 --- a/test/N3Store-test.js +++ b/test/N3Store-test.js @@ -701,6 +701,11 @@ describe('Store', () => { expect(nextDataset.match(namedNode('s2'), null, null).has(new Quad('s2', 'p2', 'o2'))).toBe(true); expect(nextDataset.match(null, namedNode('p2'), null).has(new Quad('s2', 'p2', 'o2'))).toBe(true); expect(nextDataset.match(null, null, namedNode('o2')).has(new Quad('s2', 'p2', 'o2'))).toBe(true); + expect(nextDataset.size).toBe(2); + nextDataset.add(new Quad('s2', 'p1', 'onew')); + expect(nextDataset.size).toBe(3); + nextDataset.add(new Quad('s2', 'p1', 'onew')); + expect(nextDataset.size).toBe(3); nextDataset.delete(new Quad('s2', 'p1', 'o1')); nextDataset.delete(new Quad('s2', 'p2', 'o2'));