Skip to content

Commit

Permalink
Solution of e2e timed issue [docs]: fix issue
Browse files Browse the repository at this point in the history
  • Loading branch information
zhou-yinyuan committed Aug 14, 2024
1 parent 070e57d commit 4f78a69
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,16 +62,16 @@ When running the e2e tests, all e2e tests failed because we can't get build data
<td>None</td>
</tr>
<tr>
<td>2. For the e2e test about <code>import from config file</code>, change the config file name to the e2e test config file name, and replace origin <code>input-files/*.template.json</code> file</td>
<td>If we directly use the origin file name, we will not need to modify the code. And we only upload <code>input-files/*.template.json</code> file to repo rather than <code>input-files/*.json</code>, so we must modify the <code>*.template.json</code> file</td>
<td>2. For the e2e test about <code>import from config file</code>, change the config file name to the e2e test config file name, and replace origin <code>input-files/&#42;.template.json</code> file</td>
<td>If we directly use the origin file name, we will not need to modify the code. And we only upload <code>input-files/&#42;.template.json</code> file to repo rather than <code>input-files/&#42;.json</code>, so we must modify the <code>&#42;.template.json</code> file</td>
</tr>
<tr>
<td>3. In the <code>*.template.json</code> file, for data security, we must replace token with placeholder of <code>&lt;E2E_TOKEN_JIRA&gt;</code> , <code>&lt;E2E_TOKEN_BUILD_KITE&gt;</code>,<code>&lt;E2E_TOKEN_GITHUB&gt;</code> like the previous file</td>
<td>3. In the <code>&#42;.template.json</code> file, for data security, we must replace token with placeholder of <code>&lt;E2E_TOKEN_JIRA&gt;</code> , <code>&lt;E2E_TOKEN_BUILD_KITE&gt;</code>,<code>&lt;E2E_TOKEN_GITHUB&gt;</code> like the previous file</td>
<td>We can copy the previous placeholder to use the new placeholder, And when we run <code>pnpm e2e:local</code>, the <code>generate-config-files.sh</code> file will replace the placeholder with the real token. Tips: there is an e2e test to test the pipeline that is no organization in the unhappy path, and the placeholder is <code>&lt;E2E_TOKEN_PIPELINE_NO_ORG_CONFIG_BUILDKITE&gt;</code>, maybe you need to check if the token is correct</td>
</tr>
<tr>
<td>4. Modify local token file. We will modify the origin token to the new token in the <code>.env.local</code> file to ensure that the e2e test can be passed locally</td>
<td>In the local, the placeholder from the <code>*.template.json</code> file will be replaced with the token in the <code>.env.local</code> file. And the <code>generate-config-files.sh</code> file will create a new json file with the same name by <code>*.template.json</code> file.</td>
<td>In the local, the placeholder from the <code>&#42;.template.json</code> file will be replaced with the token in the <code>.env.local</code> file. And the <code>generate-config-files.sh</code> file will create a new json file with the same name by <code>&#42;.template.json</code> file.</td>
</tr>
<tr>
<td>5. Run the e2e test, and change the report data and local csv files by the Step 1</td>
Expand All @@ -87,7 +87,7 @@ When running the e2e tests, all e2e tests failed because we can't get build data
</tr>
<tr>
<td>8. Close the playwright and rerun the cmd of <code>pnpm e2e:local</code> to re-test the e2e test</td>
<td>The reason is to ensure that all e2e tests are passed in the local env. Becausethe changes of <code>*.template.json</code> will not be hot replacement, however, when we run the <code>pnpm e2e:local</code> command, the json file will be generated by <code>generate-config-files.sh</code> file</td>
<td>The reason is to ensure that all e2e tests are passed in the local env. Becausethe changes of <code>&#42;.template.json</code> will not be hot replacement, however, when we run the <code>pnpm e2e:local</code> command, the json file will be generated by <code>generate-config-files.sh</code> file</td>
</tr>
<tr>
<td rowspan="3">Step 3. Modify the remote env to ensure that all e2e tests are passed in the remote env</td>
Expand Down

0 comments on commit 4f78a69

Please sign in to comment.