@malloydata/malloy-tests 0.0.276 → 0.0.277
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +9 -9
- package/src/core/tags.spec.ts +29 -0
package/package.json
CHANGED
|
@@ -21,14 +21,14 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@jest/globals": "^29.4.3",
|
|
24
|
-
"@malloydata/db-bigquery": "0.0.
|
|
25
|
-
"@malloydata/db-duckdb": "0.0.
|
|
26
|
-
"@malloydata/db-postgres": "0.0.
|
|
27
|
-
"@malloydata/db-snowflake": "0.0.
|
|
28
|
-
"@malloydata/db-trino": "0.0.
|
|
29
|
-
"@malloydata/malloy": "0.0.
|
|
30
|
-
"@malloydata/malloy-tag": "0.0.
|
|
31
|
-
"@malloydata/render": "0.0.
|
|
24
|
+
"@malloydata/db-bigquery": "0.0.277",
|
|
25
|
+
"@malloydata/db-duckdb": "0.0.277",
|
|
26
|
+
"@malloydata/db-postgres": "0.0.277",
|
|
27
|
+
"@malloydata/db-snowflake": "0.0.277",
|
|
28
|
+
"@malloydata/db-trino": "0.0.277",
|
|
29
|
+
"@malloydata/malloy": "0.0.277",
|
|
30
|
+
"@malloydata/malloy-tag": "0.0.277",
|
|
31
|
+
"@malloydata/render": "0.0.277",
|
|
32
32
|
"events": "^3.3.0",
|
|
33
33
|
"jsdom": "^22.1.0",
|
|
34
34
|
"luxon": "^2.4.0",
|
|
@@ -38,5 +38,5 @@
|
|
|
38
38
|
"@types/jsdom": "^21.1.1",
|
|
39
39
|
"@types/luxon": "^2.4.0"
|
|
40
40
|
},
|
|
41
|
-
"version": "0.0.
|
|
41
|
+
"version": "0.0.277"
|
|
42
42
|
}
|
package/src/core/tags.spec.ts
CHANGED
|
@@ -318,4 +318,33 @@ describe('tags in results', () => {
|
|
|
318
318
|
const fromVal = nestedTags.tag.text('from');
|
|
319
319
|
expect(fromVal).toEqual('notes');
|
|
320
320
|
});
|
|
321
|
+
test('run: from turtle inherits can disable turtle tags', async () => {
|
|
322
|
+
const run1 = runtime.loadQuery(`
|
|
323
|
+
source: one is duckdb.sql("SELECT 1 as one") extend {
|
|
324
|
+
# blockNote b1
|
|
325
|
+
view:
|
|
326
|
+
# note n2
|
|
327
|
+
view1 is { select: * }
|
|
328
|
+
}
|
|
329
|
+
# -blockNote b3
|
|
330
|
+
run:
|
|
331
|
+
# -note n4
|
|
332
|
+
one -> view1
|
|
333
|
+
`);
|
|
334
|
+
const result = await run1.run();
|
|
335
|
+
const lineSrc = result.resultExplore.getTaglines().map(s => s.trim());
|
|
336
|
+
expect(lineSrc).toEqual([
|
|
337
|
+
'# blockNote b1',
|
|
338
|
+
'# note n2',
|
|
339
|
+
'# -blockNote b3',
|
|
340
|
+
'# -note n4',
|
|
341
|
+
]);
|
|
342
|
+
const tags = result.resultExplore.tagParse().tag;
|
|
343
|
+
expect(tags.has('blockNote')).toBeFalsy();
|
|
344
|
+
expect(tags.has('note')).toBeFalsy();
|
|
345
|
+
expect(tags.has('b1')).toBeTruthy();
|
|
346
|
+
expect(tags.has('b3')).toBeTruthy();
|
|
347
|
+
expect(tags.has('n2')).toBeTruthy();
|
|
348
|
+
expect(tags.has('n4')).toBeTruthy();
|
|
349
|
+
});
|
|
321
350
|
});
|