Skip to content

Commit 672814b

Browse files
committed
chore: fix static and unit tests after major deps update
1 parent 897d4c9 commit 672814b

File tree

9 files changed

+56
-170
lines changed

9 files changed

+56
-170
lines changed

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
}
5454
},
5555
"resolutions": {
56+
"@types/express": "4",
5657
"sharp": "0.33.3",
5758
"@graphql-tools/load": "^8.0.2"
5859
}

packages/npm/@amazeelabs/estimator/src/effects/scan.test.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ test('full', async ({ repo, effectValue }) => {
1515
await repo.write('schema/fragments/a.gql', '');
1616
const result = await effectValue(scan);
1717
expect(result.map((file) => file.substr(repo.directory.length))).toEqual([
18-
'/schema/fragments/a.gql',
19-
'/schema/schema.graphqls',
2018
'/src/something.ts',
19+
'/schema/schema.graphqls',
20+
'/schema/fragments/a.gql',
2121
]);
2222
});

packages/npm/@amazeelabs/estimator/src/effects/scan.ts

+7-10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Effect } from 'effect';
2-
import glob from 'glob';
2+
import { glob } from 'glob';
33

44
import { configuration } from './configuration.js';
55

@@ -9,21 +9,18 @@ import { configuration } from './configuration.js';
99
export const scan = Effect.gen(function* () {
1010
const config = yield* configuration;
1111
const resolvedCwd = config.root;
12-
const globOpts = {
13-
absolute: true,
14-
cwd: resolvedCwd,
15-
} as Parameters<typeof glob>[1];
1612

1713
let matches: string[] = [];
1814

1915
for (const pattern of config.documents) {
2016
matches = matches.concat(
2117
yield* Effect.async<string[], Error>((resume) => {
22-
glob(pattern, globOpts, (err, matches) => {
23-
return err
24-
? resume(Effect.fail(err))
25-
: resume(Effect.succeed(matches));
26-
});
18+
glob(pattern, {
19+
absolute: true,
20+
cwd: resolvedCwd,
21+
})
22+
.then((matches) => resume(Effect.succeed(matches)))
23+
.catch((err) => resume(Effect.fail(err)));
2724
}),
2825
);
2926
}

packages/npm/@amazeelabs/molecules/eslint.config.mjs

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ import { defineConfig, frontend } from '@internal/eslint-config';
33
export default defineConfig([
44
...frontend,
55
{
6-
ignores: ['dist/**'],
6+
ignores: ['dist/**', 'storybook-static/**'],
77
},
88
]);

packages/npm/@amazeelabs/publisher-ui/src/components/Collapsible.tsx

+10-7
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,6 @@ function HeightTransition({
2828
return (
2929
<Transition
3030
show={show}
31-
style={{
32-
transitionProperty: 'height',
33-
transitionDuration: `${duration}ms`,
34-
transitionDelay: `${delay}ms`,
35-
transitionTimingFunction: 'ease-in-out',
36-
}}
3731
enterFrom="!h-0"
3832
leaveTo="!h-0"
3933
beforeEnter={() => {
@@ -61,7 +55,16 @@ function HeightTransition({
6155
afterLeave?.();
6256
}}
6357
>
64-
<div ref={ref}>{children}</div>
58+
<div
59+
style={{
60+
transitionProperty: 'height',
61+
transitionDuration: `${duration}ms`,
62+
transitionDelay: `${delay}ms`,
63+
transitionTimingFunction: 'ease-in-out',
64+
}}
65+
>
66+
<div ref={ref}>{children}</div>
67+
</div>
6568
</Transition>
6669
);
6770
}

packages/npm/@amazeelabs/publisher/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"@internal/eslint-config": "workspace:*",
4747
"@types/cookie-parser": "1.4.7",
4848
"@types/cors": "2.8.17",
49-
"@types/express": "5.0.0",
49+
"@types/express": "4.17.21",
5050
"@types/express-session": "1.18.0",
5151
"@types/express-ws": "3.0.4",
5252
"@types/fs-extra": "11.0.4",

packages/npm/verdaccio-git/src/__tests__/package.spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { IUploadTarball, Logger } from '@verdaccio/types';
22
import fs from 'fs-extra';
33
import mock from 'mock-fs';
44
import { SimpleGit } from 'simple-git';
5-
import tar from 'tar';
5+
import * as tar from 'tar';
66

77
import * as composer from '../composer';
88
import { isGitPackage, proxyTarball, pushToGit } from '../package';

packages/npm/verdaccio-git/src/package.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { IUploadTarball, Logger } from '@verdaccio/types';
22
import fs, { readJSONSync } from 'fs-extra';
33
import { SimpleGit } from 'simple-git';
4-
import tar from 'tar';
4+
import * as tar from 'tar';
55

66
import { processComposerPackage } from './composer';
77

0 commit comments

Comments
 (0)