-
Notifications
You must be signed in to change notification settings - Fork 0
Add coverage testing #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
80 commits
Select commit
Hold shift + click to select a range
2aafe1f
Add coverage testing
brahyt-sf 8803740
some doc info
brahyt-sf 0d63dc2
remove other coverage metrics
brahyt-sf 062b022
remove test header
brahyt-sf 49e47ac
added mapping for scenarios
brahyt-sf 04d58bf
scenario 4
brahyt-sf 2a73b4a
scenario 5
brahyt-sf 0468740
scene6
brahyt-sf ed13306
f
brahyt-sf 05eae09
scene7
brahyt-sf 572157d
scene8
brahyt-sf 73e53f5
added scene 9 and other stuff
brahyt-sf 87501f5
fixed logging tests
brahyt-sf 0236d8a
added more wiremock :(
brahyt-sf 67b6525
added client error mock
brahyt-sf 89f9758
added wiremock for server error
brahyt-sf 60f7110
skip unnessiary test
brahyt-sf 789f958
added more wiremock mappings
brahyt-sf 4416c9d
wiremock
brahyt-sf 2cfcc38
wiremock empty
brahyt-sf a0fa8d1
added more wiremocks
brahyt-sf 6b2601d
wiremock!
brahyt-sf c62c093
wiremock
brahyt-sf eb00966
wiremock
brahyt-sf 6dd6a5f
wiremock
brahyt-sf aa59715
mapping
brahyt-sf a9b9475
mapping
brahyt-sf 4252454
webmock
brahyt-sf c5e84fb
webmock
brahyt-sf 7aa975e
wiremock
brahyt-sf e1a1735
wiremock
brahyt-sf 0a85e15
mapping
brahyt-sf c94814b
mapping
brahyt-sf 11877bd
wiremock
brahyt-sf de0d113
wiremock
brahyt-sf be281b7
wiremock
brahyt-sf 8b4b806
wiremock
brahyt-sf 924de37
wiremock
brahyt-sf 7541610
mapssssssssssssssssssss
brahyt-sf 76660af
wiremock
brahyt-sf ffceac4
wwwwawawawawiiiiiieeeeerrrrrrmmmmap
brahyt-sf c889eaa
wiremock
brahyt-sf fabe0b4
wawawawiiiiieeeerrrrrmoooock
brahyt-sf 5061874
wm
brahyt-sf 07c4451
wm
brahyt-sf 6ba4584
soclose
brahyt-sf 9663330
1more
brahyt-sf 6cb1ce2
omg
brahyt-sf 8d84ab2
add skip message
brahyt-sf d97424e
lint
brahyt-sf aaa6203
docs
brahyt-sf 89c4548
coverage workflow
brahyt-sf de222c4
wiremock again...
brahyt-sf e849fc4
:/
brahyt-sf 1fde009
f
brahyt-sf f4810a1
dont think I need this
brahyt-sf 818c534
g
brahyt-sf cbfd53f
f
brahyt-sf 392b7a6
f
brahyt-sf a24b95f
g
brahyt-sf 55a0762
g
brahyt-sf ea9b606
f
brahyt-sf 16e8b36
g
brahyt-sf c319ae7
switch to yarn
brahyt-sf e9789a6
cross env
brahyt-sf 48edbb6
trying to fix wiremock
brahyt-sf 817608d
f
brahyt-sf 7a92db7
f
brahyt-sf 5fa9e96
akcount
brahyt-sf a298cbb
maybe...
brahyt-sf 7c8d59d
200
brahyt-sf ca7b5e2
omg
brahyt-sf be06476
try .x
brahyt-sf 47c0de3
skip weird test for now
brahyt-sf 04d3bfc
maybe fixes Macos crash
brahyt-sf 1f7598e
skip heap issue
brahyt-sf 58b65f4
testing with 100% coverage, if this fails then its working
brahyt-sf 1e7d52e
test for 100% coverage test failed successful moving back to 80%
brahyt-sf f40d370
remove macos from matrix
brahyt-sf 3165023
lint
brahyt-sf File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,5 @@ tsconfig.tsbuildinfo | |
.DS_Store | ||
src/**/*.js | ||
src/**/*.js.map | ||
**/coverage/ | ||
**/.nyc_output |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"extension": [".ts"], | ||
"include": ["src/**/*.ts"], | ||
"exclude": ["test/**"], | ||
"reporter": ["text", "html", "json-summary"], | ||
"all": true, | ||
"check-coverage": true, | ||
"lines": 80 | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
mappings/bulk-api-ingest-7508Z00000lSXvxQAG-unprocessed.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/7508Z00000lSXvxQAG/unprocessedrecords" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"headers": { | ||
"Content-Type": "text/csv" | ||
}, | ||
"body": "Name,Description,NumberOfEmployees\nTestAccount3,Yet another description,50" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/7508Z00000lSXvxQAG/successfulResults" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"headers": { | ||
"Content-Type": "text/csv" | ||
}, | ||
"body": "sf__Id,sf__Created,Name,Description,NumberOfEmployees\n0018Z00002rGc7YQAS,true,TestAccount1,Description of TestAccount1,30\n0018Z00002rGc7ZQAS,true,TestAccount2,Another description,40\n0018Z00002rGc7aQAC,true,TestAccount3,Yet another description,50" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "PATCH", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/clientError" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"headers": { | ||
"Content-Type": "application/json;charset=UTF-8" | ||
}, | ||
"body": "[{\"errorCode\":\"INVALIDJOBSTATE\",\"message\":\"Aborting already Completed Job not allowed\"}]" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"request": { | ||
"method": "PATCH", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/serverError" | ||
}, | ||
"response": { | ||
"status": 500 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"request": { | ||
"method": "PATCH", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/7508Z00000lSXvxQAG" | ||
}, | ||
"response": { | ||
"status": 200 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/clientError/failedResults" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"headers": { | ||
"Content-Type": "application/json;charset=UTF-8" | ||
}, | ||
"body": "[{\"errorCode\":\"NOT_FOUND\",\"message\":\"The requested resource does not exist\"}]" | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
mappings/bulk-api-ingest-client-error-unprocessed-records.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/clientError/unprocessedrecords" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"headers": { | ||
"Content-Type": "application/json;charset=UTF-8" | ||
}, | ||
"body": "[{\"errorCode\":\"NOT_FOUND\",\"message\":\"The requested resource does not exist\"}]" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"request": { | ||
"method": "DELETE", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/7508Z00000lSXvxQAG" | ||
}, | ||
"response": { | ||
"status": 200 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "DELETE", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/clientError" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"headers": { | ||
"Content-Type": "application/json;charset=UTF-8" | ||
}, | ||
"body": "[{\"errorCode\":\"NOT_FOUND\",\"message\":\"The requested resource does not exist\"}]" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"request": { | ||
"method": "DELETE", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/serverError" | ||
}, | ||
"response": { | ||
"status": 500 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/empty/failedResults" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"headers": { | ||
"Content-Type": "text/csv" | ||
}, | ||
"body": "sf__Id,sf__Error,Name,Description,NumberOfEmployees\n" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/empty/unprocessedrecords" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"headers": { | ||
"Content-Type": "text/csv" | ||
}, | ||
"body": "Name,Description,NumberOfEmployees\n" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/empty/successfulResults" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"headers": { | ||
"Content-Type": "text/csv" | ||
}, | ||
"body": "sf__Id,sf__Created,Name,Description,NumberOfEmployees\n" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S01", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "PUT", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/1/batches" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S01", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "PATCH", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/1" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S01", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S02", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"headers": { | ||
"Content-Type": "application/json" | ||
}, | ||
"body": "testErrorMessage" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S03", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1", | ||
"jobReference": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S03", | ||
"requiredScenarioState": "start", | ||
"newScenarioState": "start", | ||
"request": { | ||
"method": "PUT", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/1/batches" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"body": "testErrorMessage" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S04", | ||
"requiredScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S04", | ||
"requiredScenarioState": "start", | ||
"request": { | ||
"method": "PUT", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/1/batches" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S04", | ||
"requiredScenarioState": "start", | ||
"request": { | ||
"method": "PATCH", | ||
"urlPath": "/services/data/v56.0/jobs/ingest/1" | ||
}, | ||
"response": { | ||
"status": 400, | ||
"body": "testErrorMessage" | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S05", | ||
"requiredScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 500 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"scenarioName": "BULK_API_INGEST_S06", | ||
"requiredScenarioState": "start", | ||
"request": { | ||
"method": "POST", | ||
"urlPath": "/services/data/v56.0/jobs/ingest" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"jsonBody": { | ||
"id": "1" | ||
} | ||
} | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.