Skip to content

Commit

Permalink
A snapshot a day keeps the bugs away! πŸ“·πŸ› (OS: ubuntu-latest)
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Aug 21, 2024
1 parent dada9f8 commit 5da5afb
Show file tree
Hide file tree
Showing 2 changed files with 86 additions and 86 deletions.
62 changes: 31 additions & 31 deletions src/lang/artifact.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,46 +18,46 @@ const mySketch001 = startSketchOn('XY')
// @ts-ignore
const sketch001 = programMemory?.get('mySketch001')
expect(sketch001).toEqual({

type: 'UserVal',
__meta: [{ sourceRange: [46, 71] }],
value: {
type: 'SketchGroup',
on: expect.any(Object),
start: {
to: [0, 0],
from: [0, 0],
tag: null,
__geoMeta: {
id: expect.any(String),
sourceRange: [46, 71],
},
},
value: [
{
type: 'ToPoint',
tag: null,
to: [-1.59, -1.54],
type: 'SketchGroup',
on: expect.any(Object),
start: {
to: [0, 0],
from: [0, 0],
__geoMeta: {
sourceRange: [77, 102],
id: expect.any(String),
},
},
{
type: 'ToPoint',
to: [0.46, -5.82],
from: [-1.59, -1.54],
tag: null,
__geoMeta: {
sourceRange: [108, 132],
id: expect.any(String),
sourceRange: [46, 71],
},
},
],
id: expect.any(String),
__meta: [{ sourceRange: [46, 71] }],
}})
value: [
{
type: 'ToPoint',
tag: null,
to: [-1.59, -1.54],
from: [0, 0],
__geoMeta: {
sourceRange: [77, 102],
id: expect.any(String),
},
},
{
type: 'ToPoint',
to: [0.46, -5.82],
from: [-1.59, -1.54],
tag: null,
__geoMeta: {
sourceRange: [108, 132],
id: expect.any(String),
},
},
],
id: expect.any(String),
__meta: [{ sourceRange: [46, 71] }],
},
})
})
test('extrude artifacts', async () => {
// Enable rotations #152
Expand Down
110 changes: 55 additions & 55 deletions src/lang/executor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,72 +154,72 @@ const newVar = myVar + 1`
expect(mem.get('mySk1')).toEqual({
type: 'UserVal',
value: {
type: 'SketchGroup',
on: expect.any(Object),
start: {
to: [0, 0],
from: [0, 0],
tag: null,
__geoMeta: {
id: expect.any(String),
sourceRange: [39, 63],
},
},
tags: {
myPath: {
__meta: [
{
sourceRange: [109, 116],
},
],
type: 'TagIdentifier',
value: 'myPath',
info: expect.any(Object),
},
},
value: [
{
type: 'ToPoint',
to: [1, 1],
type: 'SketchGroup',
on: expect.any(Object),
start: {
to: [0, 0],
from: [0, 0],
tag: null,
__geoMeta: {
sourceRange: [69, 85],
id: expect.any(String),
sourceRange: [39, 63],
},
},
{
type: 'ToPoint',
to: [0, 1],
from: [1, 1],
__geoMeta: {
sourceRange: [91, 117],
id: expect.any(String),
},
tag: {
end: 116,
start: 109,
type: 'TagDeclarator',
tags: {
myPath: {
__meta: [
{
sourceRange: [109, 116],
},
],
type: 'TagIdentifier',
value: 'myPath',
digest: null,
info: expect.any(Object),
},
},
{
type: 'ToPoint',
to: [1, 1],
from: [0, 1],
tag: null,
__geoMeta: {
sourceRange: [123, 139],
id: expect.any(String),
value: [
{
type: 'ToPoint',
to: [1, 1],
from: [0, 0],
tag: null,
__geoMeta: {
sourceRange: [69, 85],
id: expect.any(String),
},
},
},
],
id: expect.any(String),
__meta: [{ sourceRange: [39, 63] }],
},
{
type: 'ToPoint',
to: [0, 1],
from: [1, 1],
__geoMeta: {
sourceRange: [91, 117],
id: expect.any(String),
},
tag: {
end: 116,
start: 109,
type: 'TagDeclarator',
value: 'myPath',
digest: null,
},
},
{
type: 'ToPoint',
to: [1, 1],
from: [0, 1],
tag: null,
__geoMeta: {
sourceRange: [123, 139],
id: expect.any(String),
},
},
],
id: expect.any(String),
__meta: [{ sourceRange: [39, 63] }],
})
},
__meta: [{ sourceRange: [39, 63] }],
})
})
it('execute array expression', async () => {
const code = ['const three = 3', "const yo = [1, '2', three, 4 + 5]"].join(
Expand Down

0 comments on commit 5da5afb

Please sign in to comment.