diff --git a/nx.json b/nx.json index 87f3cd2f1b..669ec4187a 100644 --- a/nx.json +++ b/nx.json @@ -31,8 +31,8 @@ "dependsOn": ["build"], "cache": true }, - "last-checks": { - "inputs": ["default", "{projectRoot}/test.ts"], + "@turf/turf:test": { + "inputs": ["default", "{projectRoot}/test.ts", "{projectRoot}/index.ts"], "dependsOn": ["build", "^last-checks"], "cache": true } diff --git a/package.json b/package.json index 3521f6e877..8570cea7d8 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "lint:prettier": "prettier --check .", "preinstall": "npx only-allow pnpm", "prepare": "husky && lerna run build", - "test": "pnpm run lint && lerna run test && lerna run --scope @turf/turf last-checks" + "test": "pnpm run lint && lerna run test" }, "lint-staged": { "package.json": [ diff --git a/packages/turf-mask/package.json b/packages/turf-mask/package.json index 725b9ae3b4..3e7e8262af 100644 --- a/packages/turf-mask/package.json +++ b/packages/turf-mask/package.json @@ -55,7 +55,6 @@ "@types/tape": "^4.2.32", "benchmark": "^2.1.4", "load-json-file": "^7.0.1", - "mkdirp": "^3.0.1", "npm-run-all": "^4.1.5", "tape": "^5.7.2", "tsup": "^8.0.1", diff --git a/packages/turf/index.ts b/packages/turf/index.ts index 2b604e2188..b75c0c7806 100644 --- a/packages/turf/index.ts +++ b/packages/turf/index.ts @@ -46,6 +46,7 @@ export { concave } from "@turf/concave"; export { convex } from "@turf/convex"; export { destination } from "@turf/destination"; export { difference } from "@turf/difference"; // JSTS Module +export { directionalMean } from "@turf/directional-mean"; export { dissolve } from "@turf/dissolve"; // JSTS Sub-Model export { distance } from "@turf/distance"; export { distanceWeight } from "@turf/distance-weight"; diff --git a/packages/turf/package.json b/packages/turf/package.json index 4855aa15c3..5e61a1905a 100644 --- a/packages/turf/package.json +++ b/packages/turf/package.json @@ -68,10 +68,9 @@ ], "scripts": { "build": "tsup --config ../../tsup.config.ts && rollup -c rollup.config.js", - "last-checks": "npm-run-all last-checks:testjs last-checks:example", - "last-checks:example": "tsx test.example.js", - "last-checks:testjs": "tsx test.ts", - "test": "echo '@turf/turf tests run in the last-checks step'" + "test": "npm-run-all test:testjs test:example", + "test:example": "tsx test.example.js", + "test:testjs": "tsx test.ts" }, "devDependencies": { "@babel/core": "^7.23.2", @@ -132,6 +131,7 @@ "@turf/convex": "workspace:^", "@turf/destination": "workspace:^", "@turf/difference": "workspace:^", + "@turf/directional-mean": "workspace:^", "@turf/dissolve": "workspace:^", "@turf/distance": "workspace:^", "@turf/distance-weight": "workspace:^", diff --git a/packages/turf/test.ts b/packages/turf/test.ts index 4d9f6c10b5..2e5e9852ad 100644 --- a/packages/turf/test.ts +++ b/packages/turf/test.ts @@ -66,9 +66,7 @@ test("turf -- invalid dependencies", (t) => { t.fail( `${name} @turf/helpers should be located in Dependencies instead of DevDependencies` ); - // if (devDependencies['mkdirp']) t.fail(`${name} tests should not have to create folders`); } - t.skip('remove "mkdirp" from testing'); t.end(); }); @@ -164,8 +162,6 @@ test("turf -- pre-defined attributes in package.json", (t) => { for (const { name, pckg } of modules) { if (pckg.author !== "Turf Authors") t.fail(name + ' (author) should be "Turf Authors"'); - // if (pckg.main !== 'main.js') t.skip(`${name} (main) must be "main.js" in package.json`); - // if (pckg.module !== 'main.es.js') t.skip(`${name} (module) must be "main.es.js" in package.json`); if (pckg["jsnext:main"]) t.fail( `${name} (jsnext:main) is no longer required in favor of using (module) in package.json` diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b6ba8f9ebc..507d0ac093 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -230,6 +230,9 @@ importers: '@turf/difference': specifier: workspace:^ version: link:../turf-difference + '@turf/directional-mean': + specifier: workspace:^ + version: link:../turf-directional-mean '@turf/dissolve': specifier: workspace:^ version: link:../turf-dissolve @@ -4256,9 +4259,6 @@ importers: load-json-file: specifier: ^7.0.1 version: 7.0.1 - mkdirp: - specifier: ^3.0.1 - version: 3.0.1 npm-run-all: specifier: ^4.1.5 version: 4.1.5 @@ -13935,12 +13935,6 @@ packages: hasBin: true dev: true - /mkdirp@3.0.1: - resolution: {integrity: sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==} - engines: {node: '>=10'} - hasBin: true - dev: true - /mock-property@1.0.3: resolution: {integrity: sha512-2emPTb1reeLLYwHxyVx993iYyCHEiRRO+y8NFXFPL5kl5q14sgTK76cXyEKkeKCHeRw35SfdkUJ10Q1KfHuiIQ==} engines: {node: '>= 0.4'}