Closed chilingling closed 1 month ago
The recent update enhances the PackageVersionFileController
to handle compatibility with unpkg by searching for possible file entries and implementing redirection when a requested file is not found. It also includes a new package.json
for a test package and additional test cases for redirecting to potential file entries.
Files | Change Summary |
---|---|
app/port/controller/PackageVersionFileController.ts |
Added #searchPossibleEntries method and redirection logic. |
test/fixtures/@cnpm/test-find-entry/package.json |
Introduced package.json with metadata for a test package. |
test/port/controller/PackageVersionFileController/listFiles.test.ts |
Added a test case for redirecting to a possible file entry. |
🐇 In the code's deep warren, changes abound,
New paths and entries, now easily found.
With tests to guide, and logic bright,
Our code hops forward, day and night.
Redirects in place, all errors take flight,
The rabbit's code, a pure delight.
🌟
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
我想请问下:
import-map
场景下使用 unpkg
特性还会不会有什么问题@fengmk2 @atian25
写单测,以及本地跑 docker 就可以了?
写单测,以及本地跑 docker 就可以了?
单测本地应该没问题,但是测试在 import-map
场景下的使用能力可能要同步太多 package 到本地,有点费劲
我想请问下:
- 有没有 beta 环境之类的?我想看看在
import-map
场景下使用unpkg
特性还会不会有什么问题- 编写测试用例有指导文档吗?我加几个测试用例。
@fengmk2 @atian25
参考现有的单测用例写吧。
我想请问下:
- 有没有 beta 环境之类的?我想看看在
import-map
场景下使用unpkg
特性还会不会有什么问题- 编写测试用例有指导文档吗?我加几个测试用例。
@fengmk2 @atian25
参考现有的单测用例写吧。
OK,这种推单测用例上来
@atian25 @fengmk2 大佬们下午好,单元测试加了,麻烦看看这样加是不是正确的,有问题 Or review我及时改。
closes https://github.com/cnpm/cnpmcore/issues/674
Summary by CodeRabbit
New Features
Tests