File tree Expand file tree Collapse file tree 12 files changed +29
-16
lines changed Expand file tree Collapse file tree 12 files changed +29
-16
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ Dockerfile
2
2
docker-compose.yml
3
3
* .ts
4
4
** /* .ts
5
- src
5
+ ** / * .test.js
6
6
.husky
7
7
.gitignore
8
8
dev-server.js
@@ -11,4 +11,6 @@ service-collection.postman_collection.json
11
11
tsconfig.json
12
12
tslint.json
13
13
logs
14
- cocverage
14
+ coverage
15
+ node_modules
16
+ publish.sh
Original file line number Diff line number Diff line change 20
20
run : |
21
21
npm ci
22
22
npm run build
23
- - name : Test
24
- run : npm run test
25
- - name : Newman Tests
26
- run : npm run test:newman
23
+ npm run test
24
+ npm run test:newman
27
25
Publish :
28
26
runs-on : ubuntu-latest
29
27
if : ${{ github.ref == 'refs/heads/main' }}
Original file line number Diff line number Diff line change 125
125
# ## Node Patch ###
126
126
# Serverless Webpack directories
127
127
.webpack /
128
- app
128
+ app /** /* .js
129
+ app /** /* .d.ts
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ FROM public.ecr.aws/lambda/nodejs:14
2
2
3
3
COPY . ${LAMBDA_TASK_ROOT}
4
4
5
- RUN npm ci
5
+ RUN npm ci --only=production
6
6
7
7
# Set the CMD to your handler (could also be done as a parameter override outside of the Dockerfile)
8
8
CMD [ "app/index.handler" ]
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change @@ -3,6 +3,4 @@ services:
3
3
app.handler :
4
4
ports :
5
5
- ' 9000:8080'
6
- build : .
7
- volumes :
8
- - .://var/task/
6
+ build : .
Original file line number Diff line number Diff line change 2
2
module . exports = {
3
3
preset : 'ts-jest' ,
4
4
testEnvironment : 'node' ,
5
+ testMatch : [
6
+ "**/__tests__/**/*.ts?(x)" ,
7
+ "**/?(*.)+(spec|test).ts?(x)"
8
+ ] ,
9
+ collectCoverage : true ,
10
+ // collectCoverageFrom: [
11
+ // "./app/**/*.ts",
12
+ // "!./app/**/*.js",
13
+ // "!./app/**/*.d.ts",
14
+ // "!./app/**/*.(spec|test).ts"
15
+ // ]
5
16
} ;
Original file line number Diff line number Diff line change 24
24
"scripts" : {
25
25
"start" : " tsc --watch --preserveWatchOutput & nodemon dev-server.js -e js -w ./app" ,
26
26
"build" : " tsc" ,
27
- "test" : " jest --coverage " ,
28
- "test:watch" : " jest --watch --coverage " ,
27
+ "test" : " jest" ,
28
+ "test:watch" : " jest --watch" ,
29
29
"test:newman" : " node dev-server.js --test" ,
30
30
"lint" : " tslint --fix -p ./tsconfig.json" ,
31
- "prettier" : " prettier --write './src/ **/*.ts?(x)'" ,
31
+ "prettier" : " prettier --write './**/*.ts?(x)'" ,
32
32
"release" : " semantic-release"
33
33
},
34
34
"husky" : {
Original file line number Diff line number Diff line change 11
11
// "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */
12
12
// "sourceMap": true, /* Generates corresponding '.map' file. */
13
13
// "outFile": "./", /* Concatenate and emit output to single file. */
14
- "outDir" : " app" , /* Redirect output structure to the directory. */
14
+ // "outDir": "app", /* Redirect output structure to the directory. */
15
15
// "rootDir": "src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
16
16
// "composite": true, /* Enable project compilation */
17
17
// "removeComments": true, /* Do not emit comments to output. */
37
37
// "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */
38
38
// "baseUrl": "./", /* Base directory to resolve non-absolute module names. */
39
39
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */
40
- // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */
40
+ "rootDirs" : [
41
+ " src" ,
42
+ " package.json"
43
+ ], /* List of root folders whose combined content represents the structure of the project at runtime. */
41
44
// "typeRoots": [], /* List of folders to include type definitions from. */
42
45
"types" : [
43
46
" node" ,
You can’t perform that action at this time.
0 commit comments