-
Notifications
You must be signed in to change notification settings - Fork 64
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
Mock services: Implement mock polling and mock issue creation #579
Mock services: Implement mock polling and mock issue creation #579
Conversation
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.
LGTM 👍
} | ||
|
||
setLandingPageTitle(): void { | ||
const appSetting = require('../../../../../package.json'); |
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.
Just a question here actually! Do we normally use relative or absolute paths for these kind of common files like package.json
o.o
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.
Hmm so far it has been relative links. But we can look into defining an absolute path for package json to make it cleaner but its only used in about 2/3 places I think. Also to define an absolute path we'd need to modify the tsconfig?
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.
Ahhhhh I see.....
Then I think as of now, we can just stick to relative paths :P
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.
I've only seen relative paths used in this context. Is there a benefit to using absolute paths?
This PR implements the
createIssue
andpollIssue
methods ofMockGithubService
andMockIssueService
respectively.In these mocked methods, the actual GitHub API is not used, but simply imitated (e.g.
createIssue
simply returns a newGithubIssue
, without using the GitHub API)With these mocked methods, we can now create new bug reports in our end-to-end tests.
To test these changes: run
npm run ng:serve:test
.This starts the app in "test" mode - the app will be using mocked services (hence the GitHub API will not be used).
You should be able to navigate to Bug Reporting Phase and create new bug reports.
Proposed commit message: