Skip to content

Commit 1ffabcd

Browse files
benkeeniclanton
authored andcommitted
Update libraries/rush-lib/src/logic/pnpm/test/PnpmOptionsConfiguration.test.ts
Co-authored-by: Ian Clanton-Thuon <iclanton@users.noreply.github.com>
1 parent 93d85a5 commit 1ffabcd

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

libraries/rush-lib/src/logic/pnpm/test/PnpmOptionsConfiguration.test.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -125,11 +125,8 @@ describe(PnpmOptionsConfiguration.name, () => {
125125
});
126126

127127
describe('updateGlobalCatalogs', () => {
128-
it('updates and saves globalCatalogs to pnpm-config.json', () => {
129-
const testConfigPath: string = path.join(__dirname, 'temp', 'pnpm-config-update-test.json');
130-
131-
const tempDir: string = path.dirname(testConfigPath);
132-
FileSystem.ensureFolder(tempDir);
128+
it('updates and saves globalCatalogs to pnpm-config.json', async () => {
129+
const testConfigPath: string = `${__dirname}/temp/pnpm-config-update-test.json`;
133130

134131
try {
135132
const initialConfig = {
@@ -139,7 +136,7 @@ describe(PnpmOptionsConfiguration.name, () => {
139136
}
140137
}
141138
};
142-
JsonFile.save(initialConfig, testConfigPath, { ensureFolderExists: true });
139+
await JsonFile.saveAsync(initialConfig, testConfigPath, { ensureFolderExists: true });
143140

144141
const pnpmConfiguration: PnpmOptionsConfiguration = PnpmOptionsConfiguration.loadFromJsonFileOrThrow(
145142
testConfigPath,

0 commit comments

Comments
 (0)