-
Notifications
You must be signed in to change notification settings - Fork 90
Feat/fetch results from api #236
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
Feat/fetch results from api #236
Conversation
754f02c to
6e5f8ef
Compare
c0283f7 to
87f7e53
Compare
87f7e53 to
51ed435
Compare
0d326d7 to
04792ff
Compare
| ]; | ||
| return { testData }; | ||
|
|
||
| const testCompareData: CompareResultsItem[] = [ |
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.
mock data for the compare results API call
| truncateHash(rev.revision), | ||
| ); | ||
| const repos = selectedRevisions.map((rev) => rev.repository_id); | ||
| const revs = selectedRevisions.map((rev) => rev.revision); |
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.
the API currently uses the long hash, so I removed the truncateHash helper here
renamed revisions to revs for consistency
| import { setSelectedRevisions } from '../../reducers/SelectedRevisions'; | ||
| import getTestData from '../utils/fixtures'; | ||
| import { render, store } from '../utils/setupTests'; | ||
| import { renderWithRouter, store } from '../utils/setupTests'; |
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 had to use the router-wrapped render due to the use of useLocation added in the CompareResultsView: useLocation() may be used only in the context of a <Router> component.
| ]; | ||
| return { testData }; | ||
|
|
||
| const testCompareData: CompareResultsItem[] = [ |
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.
mock data for the compare results API response
04792ff to
049e0a2
Compare
049e0a2 to
b199d28
Compare
* * update CI to run on master and staging nightly (#173) * update readme contributing guide * automatically create PR to merge staging to master once per week (#178) * Revert "automatically create PR to merge staging to master once per week (#178)" (#179) This reverts commit 5c7b491. * add popover to edit revision on results view (#182) * add graph column to compare results table * update snapshot for compare results * Add aria-label, add :hover for graph link * improve ui of edit revision ui (#196) * eject from react-scripts and update to react 18 (#198) * updated packages and included ones added by ejecting the app * added configurations for webpack and included config files in eslint * created separate jest config file * * moved .babelsrc to root directory * updated babel config to target 2 most recent chrome and firefox versions * added babel-plugin-transform-runtime to avoid duplication * * removed auto-generated manifest file * removed leftover comments from create-react-app * removed %PUBLIC_URL% from paths as this is no longer needed * updated tsconfig options * * created typed hooks for useDispatch and useSelector * add `void` to fix some typescript errors * updates required by React 18 * updated tests for compatibility * updated material imports to improve performance * updated readme * replace usage of useSelector with typed hook useAppSelector (#203) * use typed hooks * remove State type and replace with RootState * add express for heroku deploy (#204) * add missing packages and update lock file (#212) * change icon size make graph icon more obvious that its a link * add mock graphs link data and to the table * store revision instead of index in checkedRevisions state (#209) * edit revision ui (#214) * update lockfile (#217) * implement replace selected revision (#216) * update mock data with actual test results (#201) * open graph in new tab (#219) * add confidence icon * add muiIconButton style * remove question mark svg * add confidence icon * add confidence icon * add confidence icon * fix test * fix errors in accessibility test (#218) * fix errors in accessibility test * commented out test and added note explaining why * replace mean with median (#228) * fix url routing issue (#221) * add measurement units (#227) * add mocking branch to heroku auto-deploy (#231) * [PerfCompare] Replace Test Name and Suite Name with Header Name * unstable version warning (#239) * do not show search results when dropdown is clicked (#238) * Feedback icon + alert * update readme with deployment and feedback info (#245) * resolve production routing issue (#251) * fetch results from api (#236) * Create codecov.yml * Update codecov.yml * loading icon (#246) * pagination (#247) * [PerfCompare] disable comparing 1 revision, or more than 2, and display alert * Address change request * Adding one more check so that we don't allow more than four revisions * remove unused github actions (#259) * fix snapshot test after resolving merge conflict (#261) Co-authored-by: esanuandra <andra.esanu@softvision.com> Co-authored-by: eng_esther <eitimielo@mozilla.com> Co-authored-by: bacasandrei <beatrice.raluca.acasandrei@gmail.com> Co-authored-by: beatrice-acasandrei <69891317+beatrice-acasandrei@users.noreply.github.com>
* * update CI to run on master and staging nightly (#173) * update readme contributing guide * automatically create PR to merge staging to master once per week (#178) * Revert "automatically create PR to merge staging to master once per week (#178)" (#179) This reverts commit 5c7b491. * add popover to edit revision on results view (#182) * add graph column to compare results table * update snapshot for compare results * Add aria-label, add :hover for graph link * improve ui of edit revision ui (#196) * eject from react-scripts and update to react 18 (#198) * updated packages and included ones added by ejecting the app * added configurations for webpack and included config files in eslint * created separate jest config file * * moved .babelsrc to root directory * updated babel config to target 2 most recent chrome and firefox versions * added babel-plugin-transform-runtime to avoid duplication * * removed auto-generated manifest file * removed leftover comments from create-react-app * removed %PUBLIC_URL% from paths as this is no longer needed * updated tsconfig options * * created typed hooks for useDispatch and useSelector * add `void` to fix some typescript errors * updates required by React 18 * updated tests for compatibility * updated material imports to improve performance * updated readme * replace usage of useSelector with typed hook useAppSelector (#203) * use typed hooks * remove State type and replace with RootState * add express for heroku deploy (#204) * add missing packages and update lock file (#212) * change icon size make graph icon more obvious that its a link * add mock graphs link data and to the table * store revision instead of index in checkedRevisions state (#209) * edit revision ui (#214) * update lockfile (#217) * implement replace selected revision (#216) * update mock data with actual test results (#201) * open graph in new tab (#219) * add confidence icon * add muiIconButton style * remove question mark svg * add confidence icon * add confidence icon * add confidence icon * fix test * fix errors in accessibility test (#218) * fix errors in accessibility test * commented out test and added note explaining why * replace mean with median (#228) * fix url routing issue (#221) * add measurement units (#227) * add mocking branch to heroku auto-deploy (#231) * [PerfCompare] Replace Test Name and Suite Name with Header Name * unstable version warning (#239) * do not show search results when dropdown is clicked (#238) * Feedback icon + alert * update readme with deployment and feedback info (#245) * resolve production routing issue (#251) * fetch results from api (#236) * Create codecov.yml * Update codecov.yml * loading icon (#246) * pagination (#247) * [PerfCompare] disable comparing 1 revision, or more than 2, and display alert * Address change request * Adding one more check so that we don't allow more than four revisions * remove unused github actions (#259) * fix snapshot test after resolving merge conflict (#261) * Bumped version number to 0.9.0 Co-authored-by: esanuandra <andra.esanu@softvision.com> Co-authored-by: eng_esther <eitimielo@mozilla.com> Co-authored-by: bacasandrei <beatrice.raluca.acasandrei@gmail.com> Co-authored-by: beatrice-acasandrei <69891317+beatrice-acasandrei@users.noreply.github.com>
No description provided.