-
Notifications
You must be signed in to change notification settings - Fork 16
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
Support for continuous integration data uploads #396
Merged
austinkelleher
merged 16 commits into
1786-optimize-flushing
from
1765-continuous-uploads
Dec 16, 2020
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
6db9779
Initial continuous upload support
austinkelleher 8d22caf
More tests around continuous uploads and various improvements
austinkelleher 8196339
Additional test for FileSystemGraphObjectStore callbacks
austinkelleher 1271491
Mark step as a failure if uploading fails in a step
austinkelleher b05beb8
Export relevant functions and types from uploader
austinkelleher 5c0ad98
Remove old comment, update test descriptions.
austinkelleher b1c0804
Share graph object creation test utils across tests and cleanup
austinkelleher 43e57a9
Fix typo in test function
austinkelleher 2b1052c
Add tests for job state upload calls
austinkelleher 47843b7
Fix test function names
austinkelleher ca68b8a
Test assertion improvements
austinkelleher 06b3394
Only write prettified files to the file system on local collection
austinkelleher 55bb7b5
Change prettyFile to prettifyFiles
austinkelleher 2059ac5
Merge pull request #399 from JupiterOne/1849-unpretty-local-files
austinkelleher a627688
Merge pull request #398 from JupiterOne/1765-continuous-upload-tests
austinkelleher 6a2c2bf
Merge pull request #397 from JupiterOne/1848-test-cleanup
austinkelleher 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 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 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 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 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 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
26 changes: 26 additions & 0 deletions
26
packages/integration-sdk-private-test-utils/src/graphObject.ts
This file contains 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,26 @@ | ||
import { Entity, ExplicitRelationship } from '@jupiterone/integration-sdk-core'; | ||
import { v4 as uuid } from 'uuid'; | ||
|
||
export function createTestEntity(partial?: Partial<Entity>): Entity { | ||
return { | ||
_key: uuid(), | ||
_class: uuid(), | ||
_type: uuid(), | ||
[uuid()]: uuid(), | ||
...partial, | ||
}; | ||
} | ||
|
||
export function createTestRelationship( | ||
partial?: Partial<ExplicitRelationship>, | ||
): ExplicitRelationship { | ||
return { | ||
_key: uuid(), | ||
_toEntityKey: uuid(), | ||
_fromEntityKey: uuid(), | ||
_class: uuid(), | ||
_type: uuid(), | ||
[uuid()]: uuid(), | ||
...partial, | ||
}; | ||
} |
This file contains 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 |
---|---|---|
@@ -1,3 +1,5 @@ | ||
export * from './loadProjectStructure'; | ||
export * from './toUnixPath'; | ||
export * from './graphObjectStore'; | ||
export * from './graphObject'; | ||
export * from './util'; |
This file contains 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,5 @@ | ||
export function sleep(ms: number) { | ||
return new Promise((resolve) => { | ||
setTimeout(() => resolve(), ms); | ||
}); | ||
} |
This file contains 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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this have to be this way, digging into the
dist/
directory?