Skip to content

Commit b88c800

Browse files
committed
chores: fix unit test with package-generator
1 parent 1a51898 commit b88c800

File tree

4 files changed

+11
-8
lines changed

4 files changed

+11
-8
lines changed

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@
2222
"dependencies": {
2323
"glob": "^7.1.2",
2424
"rimraf": "^2.6.2",
25-
"yargs": "^8.0.2",
26-
"prettier": "1.17.0"
25+
"yargs": "^8.0.2"
2726
},
2827
"devDependencies": {
2928
"@commitlint/cli": "^7.5.2",

packages/package-generator/package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
"rimraf": "^2.6.2",
3232
"semver": "^5.4.1",
3333
"tslib": "^1.8.0",
34-
"yargs": "^8.0.2"
34+
"yargs": "^8.0.2",
35+
"prettier": "^1.17.0"
3536
},
3637
"devDependencies": {
3738
"@types/glob": "^5.0.35",
@@ -40,6 +41,7 @@
4041
"@types/rimraf": "^2.0.2",
4142
"@types/semver": "^5.4.0",
4243
"@types/yargs": "^8.0",
44+
"@types/prettier": "^1.16.3",
4345
"jest": "^20.0.4",
4446
"typescript": "^3.0.0"
4547
}

packages/package-generator/src/importModule.spec.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
jest.mock("prettier", () => {
2+
return {
3+
format: (content: string) => content
4+
};
5+
});
6+
17
import { importModule } from "./importModule";
28
import { ModuleGenerator } from "./ModuleGenerator";
39
import { dirname, join } from "path";

packages/service-types-generator/src/ClientGenerator.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
1-
import { serviceIdFromMetadata } from "./serviceIdFromMetadata";
2-
import { streamType } from "./streamType";
31
import { ClassicClient, Client, Configuration } from "./Components/Client";
42
import {
53
ConfigurationDefinition,
64
CustomizationDefinition,
7-
MiddlewareCustomizationDefinition,
85
RuntimeTarget,
96
TreeModel,
10-
Import,
11-
ServiceCustomizationDefinition
7+
Import
128
} from "@aws-sdk/build-types";
139
import { getServiceCustomizations } from "./ServiceCustomizations";
1410

0 commit comments

Comments
 (0)