-
Notifications
You must be signed in to change notification settings - Fork 324
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
Adds command spo listitem attachment set
#5347
Adds command spo listitem attachment set
#5347
Conversation
spo listitem attachment set
Thank you, we'll try to review it ASAP! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @MathijsVerbeeck, would you mind updating your PR to utilize ESM? Here's a breakdown of the new changes:
- Make sure that all logging is done asynchronously and awaited
await logger.log(attachmentFiles.AttachmentFiles); cli-microsoft365/src/m365/spo/commands/listitem/listitem-attachment-list.spec.ts
Lines 65 to 81 in 515b009
beforeEach(() => { log = []; logger = { log: async (msg: string) => { log.push(msg); }, logRaw: async (msg: string) => { log.push(msg); }, logToStderr: async (msg: string) => { log.push(msg); } }; loggerLogSpy = sinon.spy(logger, 'log'); loggerLogToStderrSpy = sinon.spy(logger, 'logToStderr'); sinon.stub(cli, 'getSettingWithDefaultValue').callsFake(((settingName, defaultValue) => defaultValue)); });
- Adjust the way commands are exported
export default new SpoListItemAttachmentListCommand(); - Replace all instances of
require
withimport
import command from './listitem-attachment-list.js'; - Modify all file imports within the project to have a
.js
extension
6e5d5e6
to
40054b3
Compare
717a9d2
to
98bcc91
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work @MathijsVerbeeck, I've left a few pointers you can look at. Shouldn't be too much work 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing to add! Awesome work @MathijsVerbeeck!
Closes #5222