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

feat: version 4 #550

Merged
merged 14 commits into from
May 21, 2024
Merged

feat: version 4 #550

merged 14 commits into from
May 21, 2024

Conversation

mdonnalley
Copy link
Contributor

@mdonnalley mdonnalley commented May 15, 2024

oclif testing utilities without fancy-test

Why?

We're migrating away from fancy-test for a few reasons:

  • it assumes people will use mocha as their test runner
  • there's a learning curve to writing fancy tests. Most people know how like to write their tests and don't want to bother with learning a new test framework
  • fancy-test offers a lot of useful utilities (like stubbing process.env) but it doesn't do everything that people need so people end up writing tests that are half fancy-tests and half "unfancy" tests. We'd rather enable people to write tests however they want.
  • we don't have bandwidth to support it as fully as we would like

Migration Guide

POC
oclif/plugin-not-found#632
oclif/oclif#1420

@W-15470644@

@cristiand391
Copy link
Member

cristiand391 commented May 21, 2024

QA notes:

migrate fancy-test in https://github.com/oclif/plugin-commands
done here: oclif/plugin-commands#671

⚠️ migration guide example shows expect is exported by @oclif/test

some examples have import {expect, test} from '@oclif/test' but that fails saying expect isn't exported.
current major exported it from fancy-test:

export {FancyTypes, expect} from 'fancy-test'

EDIT:
ignore my comment above, I misread the guide and thought the imports were in the after examples, checked again and everything looks good.

@cristiand391 cristiand391 merged commit 29a6f92 into main May 21, 2024
7 checks passed
@cristiand391 cristiand391 deleted the prerelease/beta branch May 21, 2024 18:06
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.

3 participants