@malloydata/malloy-tag 0.0.339 → 0.0.340
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/dist/index.d.ts +1 -3
- package/dist/index.js +4 -5
- package/dist/index.js.map +1 -1
- package/dist/{peggy/index.d.ts → parser.d.ts} +13 -4
- package/dist/parser.js +181 -0
- package/dist/parser.js.map +1 -0
- package/package.json +13 -6
- package/src/index.ts +1 -3
- package/src/parser.ts +203 -0
- package/CONTEXT.md +0 -173
- package/README.md +0 -0
- package/dist/peggy/dist/peg-tag-parser.d.ts +0 -11
- package/dist/peggy/dist/peg-tag-parser.js +0 -3130
- package/dist/peggy/dist/peg-tag-parser.js.map +0 -1
- package/dist/peggy/index.js +0 -117
- package/dist/peggy/index.js.map +0 -1
- package/dist/peggy/interpreter.d.ts +0 -32
- package/dist/peggy/interpreter.js +0 -208
- package/dist/peggy/interpreter.js.map +0 -1
- package/dist/peggy/statements.d.ts +0 -51
- package/dist/peggy/statements.js +0 -7
- package/dist/peggy/statements.js.map +0 -1
- package/dist/schema.d.ts +0 -41
- package/dist/schema.js +0 -573
- package/dist/schema.js.map +0 -1
- package/dist/schema.spec.d.ts +0 -1
- package/dist/schema.spec.js +0 -980
- package/dist/schema.spec.js.map +0 -1
- package/dist/tags.spec.d.ts +0 -8
- package/dist/tags.spec.js +0 -884
- package/dist/tags.spec.js.map +0 -1
- package/dist/util.spec.d.ts +0 -1
- package/dist/util.spec.js +0 -43
- package/dist/util.spec.js.map +0 -1
- package/src/motly-schema.motly +0 -52
- package/src/peggy/dist/peg-tag-parser.js +0 -2790
- package/src/peggy/index.ts +0 -89
- package/src/peggy/interpreter.ts +0 -265
- package/src/peggy/malloy-tag.peggy +0 -224
- package/src/peggy/statements.ts +0 -49
- package/src/schema.spec.ts +0 -1280
- package/src/schema.ts +0 -852
- package/src/tags.spec.ts +0 -967
- package/src/util.spec.ts +0 -43
- package/tsconfig.json +0 -12
package/src/util.spec.ts
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
*
|
|
4
|
-
* This source code is licensed under the MIT license found in the
|
|
5
|
-
* LICENSE file in the root directory of this source tree.
|
|
6
|
-
*/
|
|
7
|
-
import {parseString} from './util';
|
|
8
|
-
|
|
9
|
-
describe('quote comprehension inside strings', () => {
|
|
10
|
-
test('\\b', () => {
|
|
11
|
-
expect(parseString('\\b')).toEqual('\b');
|
|
12
|
-
});
|
|
13
|
-
test('\\f', () => {
|
|
14
|
-
expect(parseString('\\f')).toEqual('\f');
|
|
15
|
-
});
|
|
16
|
-
test('\\n', () => {
|
|
17
|
-
expect(parseString('\\n')).toEqual('\n');
|
|
18
|
-
});
|
|
19
|
-
test('\\r', () => {
|
|
20
|
-
expect(parseString('\\r')).toEqual('\r');
|
|
21
|
-
});
|
|
22
|
-
test('\\t', () => {
|
|
23
|
-
expect(parseString('\\t')).toEqual('\t');
|
|
24
|
-
});
|
|
25
|
-
test('unicode ?', () => {
|
|
26
|
-
expect(parseString('\\u003f')).toEqual('?');
|
|
27
|
-
expect(parseString('\\u003F')).toEqual('?');
|
|
28
|
-
});
|
|
29
|
-
test('normal stuff', () => {
|
|
30
|
-
expect(parseString('normal stuff')).toEqual('normal stuff');
|
|
31
|
-
});
|
|
32
|
-
test('stuff & nonsense', () => {
|
|
33
|
-
expect(parseString('stuff \\u0026 nonsense')).toEqual('stuff & nonsense');
|
|
34
|
-
});
|
|
35
|
-
test('one thing\\nnext thing', () => {
|
|
36
|
-
expect(parseString('one thing\\nnext thing')).toEqual(
|
|
37
|
-
'one thing\nnext thing'
|
|
38
|
-
);
|
|
39
|
-
});
|
|
40
|
-
test('quote stripping works', () => {
|
|
41
|
-
expect(parseString('|42|', '|')).toEqual('42');
|
|
42
|
-
});
|
|
43
|
-
});
|