circuitscript 0.0.18 → 0.0.19

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.
@@ -438,4 +438,109 @@ to v5v`,
438
438
  [ '/NET_2', 'led_with_res_0.res_0.COMP_1_1k', 1 ],
439
439
  [ '/NET_2', 'led_with_res_1.led_1.COMP_1_0603', 1 ],
440
440
  [ '/NET_2', 'led_with_res_1.res_1.COMP_1_1k', 1 ]
441
- ]);
441
+ ]);
442
+
443
+
444
+
445
+ /**
446
+ Tests the `point` branching keyword
447
+ */
448
+ export const script14 = new ScriptTest(`
449
+ import lib
450
+
451
+ v5v = supply("5V")
452
+ gnd = dgnd()
453
+
454
+ at v5v
455
+ wire down 20
456
+ add res(360) down
457
+ wire down 20
458
+
459
+ point:
460
+ at v5v
461
+ wire down 20
462
+ add res(360) down
463
+ wire down 20
464
+
465
+ branch:
466
+ wire left 100
467
+ to point
468
+
469
+ wire down 20
470
+ add res(360) down
471
+ wire down 20
472
+ to gnd
473
+
474
+ at point
475
+ wire right 200 down 20
476
+ add res(360) down
477
+ wire down 20
478
+ to gnd
479
+
480
+ wire down 20
481
+ add led("red") down
482
+ wire down 40
483
+ to gnd`, [
484
+ [ '/5V', 'v5v', 1 ],
485
+ [ '/5V', 'v5v:0', 1 ],
486
+ [ '/5V', 'res_0.COMP_1_360', 1 ],
487
+ [ '/5V', 'v5v:1', 1 ],
488
+ [ '/5V', 'res_1.COMP_1_360', 1 ],
489
+ [ '/GND', 'gnd', 1 ],
490
+ [ '/GND', 'gnd:0', 1 ],
491
+ [ '/GND', 'res_2.COMP_1_360', 2 ],
492
+ [ '/GND', 'gnd:1', 1 ],
493
+ [ '/GND', 'res_3.COMP_1_360', 2 ],
494
+ [ '/GND', 'gnd:2', 1 ],
495
+ [ '/GND', 'led_0.COMP_1_0603', 2 ],
496
+ [ '/NET_1', 'res_0.COMP_1_360', 2 ],
497
+ [ '/NET_1', '_point.__.0', 1 ],
498
+ [ '/NET_1', 'res_1.COMP_1_360', 2 ],
499
+ [ '/NET_1', 'res_2.COMP_1_360', 1 ],
500
+ [ '/NET_1', 'res_3.COMP_1_360', 1 ],
501
+ [ '/NET_1', 'led_0.COMP_1_0603', 1 ]
502
+ ]);
503
+
504
+ /*
505
+ Test with `paralell` keyword
506
+ */
507
+ export const script15 = new ScriptTest(`
508
+ import lib
509
+
510
+ v5v = supply("5V")
511
+ gnd = dgnd()
512
+
513
+ at v5v
514
+ wire down 20
515
+
516
+ parallel:
517
+ wire down 20
518
+ add res(1k) down
519
+ wire down 20
520
+
521
+ parallel:
522
+ wire right 60 down 20
523
+ add res(1k) down
524
+ wire auto
525
+
526
+ parallel:
527
+ wire right 120 down 20
528
+ add res(1k) down
529
+ wire auto
530
+
531
+ wire down 20
532
+ to gnd
533
+ `, [
534
+ ['/5V', 'v5v', 1],
535
+ ['/5V', 'v5v:0', 1],
536
+ ['/5V', '_parallel.__.0', 1],
537
+ ['/5V', 'res_0.COMP_1_1k', 1],
538
+ ['/5V', 'res_1.COMP_1_1k', 1],
539
+ ['/5V', 'res_2.COMP_1_1k', 1],
540
+ ['/GND', 'gnd', 1],
541
+ ['/GND', 'res_0.COMP_1_1k', 2],
542
+ ['/GND', '_parallel.__.1', 1],
543
+ ['/GND', 'res_1.COMP_1_1k', 2],
544
+ ['/GND', 'res_2.COMP_1_1k', 2],
545
+ ['/GND', 'gnd:0', 1]
546
+ ]);
@@ -0,0 +1,26 @@
1
+ import lib
2
+
3
+ v5v = supply("5V")
4
+ gnd = dgnd()
5
+
6
+ # example with `parallel` keyword
7
+ at v5v
8
+ wire down 20
9
+
10
+ parallel:
11
+ wire down 20
12
+ add res(1k) down
13
+ wire down 20
14
+
15
+ parallel:
16
+ wire right 60 down 20
17
+ add res(1k) down
18
+ wire auto
19
+
20
+ parallel:
21
+ wire right 120 down 20
22
+ add res(1k) down
23
+ wire auto
24
+
25
+ wire down 20
26
+ to gnd
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev/svgjs" width="210" height="290.5" viewBox="-25 -25.5 210 290.5"><g transform="matrix(1,0,0,1,0,0)"><path d="M -20 -20.5 L -20 260 M 0 -20.5 L 0 260 M 20 -20.5 L 20 260 M 40 -20.5 L 40 260 M 60 -20.5 L 60 260 M 80 -20.5 L 80 260 M 100 -20.5 L 100 260 M 120 -20.5 L 120 260 M 140 -20.5 L 140 260 M 160 -20.5 L 160 260 M 180 -20.5 L 180 260" fill="none" stroke-dasharray="1,19" stroke-width="1" stroke="#aaaaaa"></path></g><g transform="matrix(1,0,0,1,20,30)"><g><path d="M -15 0 L 15 0" stroke-width="1" stroke="#333333" fill="none"></path><path d="M 0 10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,-5)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">5V</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,60)"><g><path d="M 0 0 L 0 0" stroke-width="2" stroke="#333333"></path></g></g><g transform="matrix(1,0,0,1,20,120)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1k</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R1</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,180)"><g><path d="M 0 0 L 0 0" stroke-width="2" stroke="#333333"></path></g></g><g transform="matrix(1,0,0,1,80,120)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1k</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R2</tspan></text></g></g></g><g transform="matrix(1,0,0,1,140,120)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1k</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R3</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,210)"><g><path d="M -10 0 L 10 0 L 0 10 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M 0 -10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">GND</tspan></text></g></g></g><g><line x1="20" y1="40" x2="20" y2="60" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="60" x2="20" y2="80" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="60" x2="80" y2="60" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="80" y1="60" x2="80" y2="80" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="80" y1="60" x2="140" y2="60" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="140" y1="60" x2="140" y2="80" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,17.5,57.5)" fill="#008400" stroke="none"></circle><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,77.5,57.5)" fill="#008400" stroke="none"></circle><line x1="20" y1="160" x2="20" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="80" y1="160" x2="80" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="80" y1="180" x2="20" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="140" y1="160" x2="140" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="140" y1="180" x2="80" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="180" x2="20" y2="200" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,17.5,177.5)" fill="#008400" stroke="none"></circle><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,77.5,177.5)" fill="#008400" stroke="none"></circle></g><g></g></svg>
@@ -0,0 +1,37 @@
1
+ # Test `point` keyword
2
+
3
+ import lib
4
+
5
+ v5v = supply("5V")
6
+ gnd = dgnd()
7
+
8
+ at v5v
9
+ wire down 20
10
+ add res(360) down
11
+ wire down 20
12
+
13
+ point:
14
+ at v5v
15
+ wire down 20
16
+ add res(360) down
17
+ wire down 20
18
+
19
+ branch:
20
+ wire left 100
21
+ to point
22
+
23
+ wire down 20
24
+ add res(360) down
25
+ wire down 20
26
+ to gnd
27
+
28
+ at point
29
+ wire right 200 down 20
30
+ add res(360) down
31
+ wire down 20
32
+ to gnd
33
+
34
+ wire down 20
35
+ add led("red") down
36
+ wire down 40
37
+ to gnd
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev/svgjs" width="290" height="370.5" viewBox="-25 -25.5 290 370.5"><g transform="matrix(1,0,0,1,0,0)"><path d="M -20 -20.5 L -20 340 M 0 -20.5 L 0 340 M 20 -20.5 L 20 340 M 40 -20.5 L 40 340 M 60 -20.5 L 60 340 M 80 -20.5 L 80 340 M 100 -20.5 L 100 340 M 120 -20.5 L 120 340 M 140 -20.5 L 140 340 M 160 -20.5 L 160 340 M 180 -20.5 L 180 340 M 200 -20.5 L 200 340 M 220 -20.5 L 220 340 M 240 -20.5 L 240 340 M 260 -20.5 L 260 340" fill="none" stroke-dasharray="1,19" stroke-width="1" stroke="#aaaaaa"></path></g><g transform="matrix(1,0,0,1,20,30)"><g><path d="M -15 0 L 15 0" stroke-width="1" stroke="#333333" fill="none"></path><path d="M 0 10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,-5)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">5V</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,100)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">360</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R1</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,160)"><g><path d="M 0 0 L 0 0" stroke-width="2" stroke="#333333"></path></g></g><g transform="matrix(1,0,0,1,120,30)"><g><path d="M -15 0 L 15 0" stroke-width="1" stroke="#333333" fill="none"></path><path d="M 0 10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,-5)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">5V</tspan></text></g></g></g><g transform="matrix(1,0,0,1,120,100)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">360</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R2</tspan></text></g></g></g><g transform="matrix(1,0,0,1,120,220)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">360</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R3</tspan></text></g></g></g><g transform="matrix(1,0,0,1,120,290)"><g><path d="M -10 0 L 10 0 L 0 10 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M 0 -10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">GND</tspan></text></g></g></g><g transform="matrix(1,0,0,1,220,220)"><g><path d="M 9.999999999999998 -20 L 10.000000000000002 20 L -9.999999999999998 20 L -10.000000000000002 -20 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M -2.4492935982947065e-15 -40 L -1.2246467991473533e-15 -20 M 2.4492935982947065e-15 40 L 1.2246467991473533e-15 20" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999987,-22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.0000000000000013,22)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-1,6.123233995736766e-17)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="middle" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">360</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,14.999999999999998,-20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">R4</tspan></text></g></g></g><g transform="matrix(1,0,0,1,220,290)"><g><path d="M -10 0 L 10 0 L 0 10 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M 0 -10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">GND</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,210)"><g><path d="M -10 -10 L 10 -10 L 6.123233995736766e-16 10 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M 10 10 L -10 10" stroke-width="1" stroke="#333333" fill="none"></path><path d="M -8 4.898587196589413e-16 L -18 5.000000000000001" stroke-width="1" stroke="#333333" fill="none"></path><path d="M -8 3.0000000000000004 L -18 8.000000000000002" stroke-width="1" stroke="#333333" fill="none"></path><path d="M -1.83697019872103e-15 -30 L -6.123233995736766e-16 -10 M 1.83697019872103e-15 30 L 6.123233995736766e-16 10" stroke-width="2" stroke="#333333"></path><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,1.9999999999999993,-12)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="end" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,2.000000000000001,12)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="8" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">2</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-4.999999999999999,15)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="hanging" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">D1</tspan></text></g><g transform="matrix(6.123233995736766e-17,1,-1,6.123233995736766e-17,-25,15.000000000000002)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="start" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">red</tspan></text></g></g></g><g transform="matrix(1,0,0,1,20,290)"><g><path d="M -10 0 L 10 0 L 0 10 Z" stroke-width="1" stroke="#333333" fill="#ffffff"></path><path d="M 0 -10 L 0 0" stroke-width="2" stroke="#333333"></path><g transform="matrix(1,0,0,1,0,20)"><text fill="#333333" font-family="Open Sans-Regular, Arial" font-size="10" text-anchor="middle" dominant-baseline="text-top" font-weight="regular" transform="matrix(1,0,0,1,0,0)" svgjs:data="{&quot;leading&quot;:&quot;1.3&quot;}"><tspan dy="0" x="0" svgjs:data="{&quot;newLined&quot;:true}">GND</tspan></text></g></g></g><g><line x1="20" y1="40" x2="20" y2="60" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="120" y1="40" x2="120" y2="60" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="140" x2="20" y2="160" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="120" y1="140" x2="120" y2="160" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="120" y1="160" x2="20" y2="160" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="120" y1="160" x2="120" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="120" y1="160" x2="220" y2="160" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="220" y1="160" x2="220" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="160" x2="20" y2="180" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,17.5,157.5)" fill="#008400" stroke="none"></circle><circle r="2.5" cx="2.5" cy="2.5" transform="matrix(1,0,0,1,117.5,157.5)" fill="#008400" stroke="none"></circle><line x1="120" y1="260" x2="120" y2="280" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="220" y1="260" x2="220" y2="280" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line><line x1="20" y1="240" x2="20" y2="280" stroke-linecap="square" stroke-width="1" stroke="#008400" fill="none"></line></g><g></g></svg>
@@ -1,6 +1,7 @@
1
1
 
2
2
  import { findItem, findItemByRefDes, runScript } from './helpers.js';
3
- import { script1, script10, script11, script12, script13, script2, script3, script6, script7, script8, script9 } from './parseScripts.js';
3
+ import { script1, script10, script11, script12, script13, script14, script15, script2,
4
+ script3, script6, script7, script8, script9 } from './parseScripts.js';
4
5
 
5
6
  describe('test parsing', () => {
6
7
 
@@ -15,7 +16,9 @@ describe('test parsing', () => {
15
16
  ["assignment in at/to/add statement", script10],
16
17
  ["net namespace local and global", script11],
17
18
  ["create component with __is_net", script12],
18
- ["corret nets after function call", script13],
19
+ ["corret nets after function call and also `join` keyword", script13],
20
+ ["path with 'point' keyword", script14],
21
+ ["path with 'parallel' keyword", script15],
19
22
 
20
23
  ])('parse script - %s', async (description, scriptTest) => {
21
24
  // Test only parsing, does not check the correctness of the
@@ -14,7 +14,9 @@ describe('Render tests', () => {
14
14
  ['simple frame', 'script3.cst'],
15
15
  ['drawing functions for graphics', 'script4.cst'],
16
16
  ['drawing 180 deg flipped components', 'script5.cst'],
17
- ['join command', 'script6.cst']
17
+ ['join command', 'script6.cst'],
18
+ ['parallel command', 'script7.cst'],
19
+ ['point block command', 'script8.cst']
18
20
 
19
21
  ])('render - %s (%s)', async (title, scriptPath) => {
20
22