Skip to content

Commit 86e562a

Browse files
SDK regeneration (#198)
Co-authored-by: fern-api <115122769+fern-api[bot]@users.noreply.github.com>
1 parent bfa3fe6 commit 86e562a

File tree

319 files changed

+44720
-9822
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

319 files changed

+44720
-9822
lines changed

jest.config.mjs

Lines changed: 46 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,49 @@
22
export default {
33
preset: "ts-jest",
44
testEnvironment: "node",
5-
moduleNameMapper: {
6-
"(.+)\.js$": "$1",
7-
},
8-
workerThreads: true,
9-
};
5+
projects: [
6+
{
7+
displayName: "unit",
8+
preset: "ts-jest",
9+
testEnvironment: "node",
10+
moduleNameMapper: {
11+
"^(\.{1,2}/.*)\.js$": "$1",
12+
},
13+
roots: ["<rootDir>/tests"],
14+
testPathIgnorePatterns: ["\.browser\.(spec|test)\.[jt]sx?$", "/tests/wire/", "/tests/integration/"],
15+
setupFilesAfterEnv: [],
16+
},
17+
{
18+
displayName: "browser",
19+
preset: "ts-jest",
20+
testEnvironment: "<rootDir>/tests/BrowserTestEnvironment.ts",
21+
moduleNameMapper: {
22+
"^(\.{1,2}/.*)\.js$": "$1",
23+
},
24+
roots: ["<rootDir>/tests"],
25+
testMatch: ["<rootDir>/tests/unit/**/?(*.)+(browser).(spec|test).[jt]s?(x)"],
26+
setupFilesAfterEnv: [],
27+
},
28+
{
29+
displayName: "wire",
30+
preset: "ts-jest",
31+
testEnvironment: "node",
32+
moduleNameMapper: {
33+
"^(\.{1,2}/.*)\.js$": "$1",
34+
},
35+
roots: ["<rootDir>/tests/wire"],
36+
setupFilesAfterEnv: ["<rootDir>/tests/mock-server/setup.ts"],
37+
},
38+
{
39+
displayName: "integration",
40+
preset: "ts-jest",
41+
testEnvironment: "node",
42+
moduleNameMapper: {
43+
"^(\.{1,2}/.*)\.js$": "$1",
44+
},
45+
roots: ["<rootDir>/tests/integration"],
46+
},
47+
],
48+
workerThreads: false,
49+
passWithNoTests: true,
50+
};

package.json

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,49 +2,54 @@
22
"name": "square",
33
"version": "43.0.1",
44
"private": false,
5-
"repository": "https://github.com/square/square-nodejs-sdk",
5+
"repository": "github:square/square-nodejs-sdk",
66
"license": "MIT",
77
"main": "./index.js",
88
"types": "./index.d.ts",
99
"scripts": {
1010
"format": "prettier . --write --ignore-unknown",
1111
"build": "tsc",
1212
"prepack": "cp -rv dist/. .",
13-
"test": "yarn test:unit",
14-
"test:unit": "jest --testPathPattern=tests/unit",
15-
"test:integration": "jest --testPathPattern=tests/integration"
13+
"test": "jest --selectProjects unit browser wire",
14+
"test:unit": "jest --selectProjects unit",
15+
"test:browser": "jest --selectProjects browser",
16+
"test:wire": "jest --selectProjects wire",
17+
"test:integration": "jest --selectProjects integration"
1618
},
1719
"dependencies": {
18-
"url-join": "4.0.1",
1920
"form-data": "^4.0.0",
2021
"formdata-node": "^6.0.3",
2122
"node-fetch": "^2.7.0",
22-
"qs": "^6.13.1",
2323
"readable-stream": "^4.5.2",
24-
"js-base64": "3.7.7",
2524
"form-data-encoder": "^4.0.2",
2625
"square-legacy": "npm:square@^39.1.1"
2726
},
2827
"devDependencies": {
29-
"@types/url-join": "4.0.1",
30-
"@types/qs": "^6.9.17",
3128
"@types/node-fetch": "^2.6.12",
3229
"@types/readable-stream": "^4.0.18",
3330
"webpack": "^5.97.1",
3431
"ts-loader": "^9.5.1",
3532
"jest": "^29.7.0",
33+
"@jest/globals": "^29.7.0",
3634
"@types/jest": "^29.5.14",
37-
"ts-jest": "^29.1.1",
35+
"ts-jest": "^29.3.4",
3836
"jest-environment-jsdom": "^29.7.0",
37+
"msw": "^2.8.4",
3938
"@types/node": "^18.19.70",
4039
"prettier": "^3.4.2",
4140
"typescript": "~5.7.2"
4241
},
4342
"browser": {
4443
"fs": false,
4544
"os": false,
46-
"path": false
45+
"path": false,
46+
"stream": false
4747
},
48+
"packageManager": "[email protected]",
49+
"engines": {
50+
"node": ">=18.0.0"
51+
},
52+
"sideEffects": false,
4853
"description": "Use Square APIs to manage and run business including payment, customer, product, inventory, and employee management.",
4954
"author": {
5055
"name": "Square Developer Platform",

0 commit comments

Comments
 (0)