Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(deps): update dependencies #256

Merged
merged 1 commit into from
Feb 11, 2022
Merged

Conversation

john-u
Copy link
Contributor

@john-u john-u commented Feb 11, 2022

- pin log4js@6.3.0 until ESM bug is resolved (see oclif/oclif/issues/695)
- remove `generate` command as it was not functional
- add missing/remove redundant dependencies from lerna packages
const readFileMock = (fs.readFileSync as unknown as jest.Mock<Buffer, [fs.PathLike]>)
.mockImplementation(() => { throw { code: 'ENOENT' } })
const writeFileMock = fs.writeFileSync as jest.Mock<typeof fs.writeFileSync>
const chmodMock = fs.chmod as unknown as jest.Mock<void, [PathLike, string | number, NoParamCallback]>

const getPortMock = (getPort as unknown as jest.Mock<Promise<number>, [getPort.Options | undefined]>)
const getPortMock = jest.mocked(getPort)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome...I need to remember to use it from now on!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, it was just added in Jest 27. used to be a hidden util in ts-jest.

@@ -57,7 +57,7 @@ export default class ConfigCommand extends SmartThingsCommand {
]
const tableFieldDefinitions: TableFieldDefinition<ConfigItem>[] = [
...listTableFieldDefinitions,
{ label: 'Definition', value: (item) => yaml.safeDump(item.data) },
{ label: 'Definition', value: (item) => yaml.dump(item.data) },
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of these are equivalently "safe". See migration-guide-from-js-yaml3-to-js-yaml4

@john-u john-u merged commit 24d0c23 into SmartThingsCommunity:master Feb 11, 2022
@john-u john-u deleted the fix-deps branch February 11, 2022 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants