Skip to content

Commit

Permalink
test(*): add extra test scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
cabljac committed Apr 23, 2024
1 parent 650d945 commit d8729b9
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 8 deletions.
1 change: 1 addition & 0 deletions auth-mailchimp-sync/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "jest",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
},
"dependencies": {
Expand Down
2 changes: 0 additions & 2 deletions delete-user-data/functions/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,6 @@ const databaseURL = getDatabaseUrl(
config.selectedDatabaseInstance,
config.selectedDatabaseLocation
);
console.log("");

// Initialize the Firebase Admin SDK
admin.initializeApp({
credential: admin.credential.applicationDefault(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"compile": "tsc",
"test:local": "jest",
"prepare": "npm run build",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest",
"generate-stresstest-table": "bq query --project_id=extensions-testing --use_legacy_sql=false < ./src/__tests__/fixtures/sql/generateSnapshotStresstestTable.sql"
},
"files": [
Expand Down
4 changes: 4 additions & 0 deletions firestore-bigquery-export/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "jest",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest && npm run testChangeTracker && npm run testImportScript && npm run testGenSchemaScript",
"testChangeTracker": "cd ../firestore-bigquery-change-tracker && npm install && npm run testIfEmulatorRunning",
"testImportScript": "cd ../scripts/import && npm install && npm run testIfEmulatorRunning",
"testGenSchemaScript": "cd ../scripts/gen-schema-view && npm install && npm run testIfEmulatorRunning",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
},
"author": "Jan Wyszynski <[email protected]>",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"compile": "tsc && cp -r src/__tests__/fixtures lib/__tests__",
"gen-schema-views": "node ./lib/index.js",
"prepare": "npm run build",
"test": "jest"
"test": "jest",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"files": [
"lib",
Expand Down
3 changes: 2 additions & 1 deletion firestore-bigquery-export/scripts/import/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
"compile": "tsc",
"import": "node ./lib/index.js",
"prepare": "npm run build",
"test:local": "jest"
"test:local": "jest",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"files": [
"lib"
Expand Down
1 change: 1 addition & 0 deletions firestore-counter/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"compile": "tsc",
"format": "prettier --write {,**/}*.{yaml,ts,md}",
"test:local": "jest",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
},
"private": true
Expand Down
3 changes: 2 additions & 1 deletion firestore-shorten-urls-bitly/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "echo \"Error: no test specified\" && exit 1",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
"generate-readme": "firebase ext:info .. --markdown > ../README.md",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"dependencies": {
"axios": "^1.6.0",
Expand Down
3 changes: 2 additions & 1 deletion firestore-translate-text/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "jest",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
"generate-readme": "firebase ext:info .. --markdown > ../README.md",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"dependencies": {
"@google-cloud/translate": "^8.2.0",
Expand Down
3 changes: 2 additions & 1 deletion rtdb-limit-child-nodes/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "echo \"Error: no test specified\" && exit 1",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
"generate-readme": "firebase ext:info .. --markdown > ../README.md",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"license": "Apache-2.0",
"dependencies": {
Expand Down
3 changes: 2 additions & 1 deletion storage-resize-images/functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"clean": "rimraf lib",
"compile": "tsc",
"test": "jest",
"generate-readme": "firebase ext:info .. --markdown > ../README.md"
"generate-readme": "firebase ext:info .. --markdown > ../README.md",
"testIfEmulatorRunning": "wait-on tcp:4001 && jest"
},
"dependencies": {
"@types/node": "^20.10.3",
Expand Down

0 comments on commit d8729b9

Please sign in to comment.