bud
bud copied to clipboard
tests: move specs from `tests/unit/**/*` into packages
This is too big a process to hinge on a single PR. We'll take it on piecemeal until tests/unit is empty. Then we'll close this issue.
This PR lays the groundwork: https://github.com/roots/bud/pull/1623.
Tests should:
- be alongside their corresponding module
- import code directly from that module
- be named roughly in accordance with the pattern established in #1623.
-
@roots/bud-api/src/methods/assets/index.tsbecomes:-
@roots/bud-api/src/methods/assets/assets.method.ts -
@roots/bud-api/src/methods/assets/assets.unit.test.ts
-
-
There are about 500 unit tests in the repo, we'll start by tracking progress on @roots/bud-api 😅:
@roots/bud-api
- [ ]
@roots/bud-api/methods/alias - [x]
@roots/bud-api/methods/assets(#1623) - [x]
@roots/bud-api/methods/bundle(#1623) - [x]
@roots/bud-api/methods/config(#1623) - [x]
@roots/bud-api/methods/define(#1623) - [ ]
@roots/bud-api/methods/devtool - [ ]
@roots/bud-api/methods/entry - [ ]
@roots/bud-api/methods/experiments - [ ]
@roots/bud-api/methods/externals - [ ]
@roots/bud-api/methods/hash - [ ]
@roots/bud-api/methods/minimize - [ ]
@roots/bud-api/methods/persist - [ ]
@roots/bud-api/methods/provide - [ ]
@roots/bud-api/methods/proxy - [ ]
@roots/bud-api/methods/runtime - [x]
@roots/bud-api/methods/serve(#1623) - [ ]
@roots/bud-api/methods/splitChunks - [ ]
@roots/bud-api/methods/template - [ ]
@roots/bud-api/methods/use - [ ]
@roots/bud-api/methods/watch - [x]
@roots/bud-api/service(#1623)
@roots/bud-server
- [x] all existing tests (#1606)