Skip to content

Commit

Permalink
🐛 Fix validator for npm module name
Browse files Browse the repository at this point in the history
  • Loading branch information
TomokiMiyauci committed Jun 5, 2021
1 parent 488aa8e commit cca5496
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 16 deletions.
6 changes: 3 additions & 3 deletions cli/_utils_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Deno.test("uniqFlatten", () => {
assertEquals(
uniqFlatten(val),
expected,
`query2Direct(${val}) -> ${expected}`,
`uniqFlatten(${val}) -> ${expected}`,
);
});
});
Expand Down Expand Up @@ -83,8 +83,8 @@ Deno.test("query2Direct", async () => {
"@",
{
error: {
"deno.land": "Name length must be greater equal than 3",
"nest.land": "Name length must be greater equal than 2",
"deno.land": "Name length must be greater than 2",
"nest.land": "Name length must be greater than 1",
},
errorRegistry: ["deno.land", "nest.land"],
hasError: true,
Expand Down
2 changes: 1 addition & 1 deletion deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,6 @@ export {
validateDenoLand,
validateNestLand,
validateNpm,
} from "https://deno.land/x/is_valid_package_name@v1.0.0-beta.9/mod.ts";
} from "https://deno.land/x/is_valid_package_name@v1.0.0-beta.10/mod.ts";

export type { AnyFn } from "https://deno.land/x/fonction@v1.8.1/mod.ts";
7 changes: 2 additions & 5 deletions dev_deps.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// Copyright 2021-present the Registerable authors. All rights reserved. MIT license.
export { assertEquals } from "https://deno.land/std/testing/asserts.ts";
export {
endsWith,
isArray,
} from "https://deno.land/x/fonction@v1.8.0-beta.5/mod.ts";
export { assertEquals } from "https://deno.land/std@0.97.0/testing/asserts.ts";
export { endsWith, isArray } from "https://deno.land/x/fonction@v1.8.1/mod.ts";
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
"@miyauci/is-valid": "1.0.0-beta.9",
"cross-fetch": "^3.1.4",
"fonction": "^1.8.1",
"is-valid-package-name": "1.0.0-beta.9",
"is-valid-package-name": "1.0.0-beta.10",
"yargs": "^17.0.1"
},
"publishConfig": {
Expand Down
2 changes: 1 addition & 1 deletion registerable_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Deno.test("registerable", async () => {
result: { "deno.land": false, npm: false },
hasError: true,
error: {
"deno.land": "Name length must be greater equal than 3",
"deno.land": "Name length must be greater than 2",
},
errorRegistry: ["deno.land"],
name: "-",
Expand Down
2 changes: 1 addition & 1 deletion rollup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const replaceOption = {
".ts": "",
"https://deno.land/x/fonction@v1.8.1/mod": "fonction",
"https://deno.land/x/is_valid@v1.0.0-beta.9/mod": "@miyauci/is-valid",
"https://deno.land/x/is_valid_package_name@v1.0.0-beta.9/mod":
"https://deno.land/x/is_valid_package_name@v1.0.0-beta.10/mod":
"is-valid-package-name",
preventAssignment: true
};
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3438,10 +3438,10 @@ is-utf8@^0.2.1:
resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72"
integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI=

is-valid-package-name@1.0.0-beta.9:
version "1.0.0-beta.9"
resolved "https://registry.yarnpkg.com/is-valid-package-name/-/is-valid-package-name-1.0.0-beta.9.tgz#451e2c5c9799b97d7fa03c845b8ee22a8ee79c16"
integrity sha512-9JMzskljXUvA1Cy9i8PbNyGgXxenBIbErVlMs6e0yHnchAbkm2aNJy+LeE9taiCqzMTzi45JhVKDBV5ZXACTwg==
is-valid-package-name@1.0.0-beta.10:
version "1.0.0-beta.10"
resolved "https://registry.yarnpkg.com/is-valid-package-name/-/is-valid-package-name-1.0.0-beta.10.tgz#9246be283409932bd090424753df244390fff2b0"
integrity sha512-JI8+JWrNn0+SQtDu+BGPsaW6WjGy7HY6kdljKwWYYrlQLw8j/tqQDZGisgiVPDaUuuY9/dn2k7pEuhuvQotPKQ==
dependencies:
"@miyauci/is-valid" "1.0.0-beta.9"
fonction "^1.8.1"
Expand Down

0 comments on commit cca5496

Please sign in to comment.