Skip to content

Commit ba869e5

Browse files
committed
Footer: move Email Support to the support page
1 parent 23b904a commit ba869e5

File tree

4 files changed

+17
-5
lines changed

4 files changed

+17
-5
lines changed

app/components/footer.hbs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
<h1>Get Help</h1>
1414
<ul role="list">
1515
<li><a href="https://doc.rust-lang.org/cargo/">The Cargo Book</a></li>
16-
<li><a href="mailto:[email protected]">Email Support</a></li>
1716
<li><LinkTo @route="support" @query={{this.pristineSupportQuery}}>Support</LinkTo></li>
1817
<li><a href="https://status.crates.io/">System Status</a></li>
1918
<li><a href="https://github.com/rust-lang/crates.io/issues/new/choose">Report a bug</a></li>

app/templates/support.hbs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,15 @@
2323
</LinkTo>
2424
</li>
2525
{{/each}}
26+
<li>
27+
<a
28+
href="mailto:[email protected]"
29+
data-test-id="link-email-support"
30+
local-class="link"
31+
>
32+
For all other cases
33+
</a>
34+
</li>
2635
</ul>
2736
</section>
2837
{{/if}}

e2e/acceptance/support.spec.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ test.describe('Acceptance | support page', { tag: '@acceptance' }, () => {
99
await expect(page.getByTestId('inquire-list-section')).toBeVisible();
1010
const inquireList = page.getByTestId('inquire-list');
1111
await expect(inquireList).toBeVisible();
12-
await expect(inquireList.locator(page.getByRole('listitem'))).toHaveText(['Report a crate that violates policies']);
12+
await expect(inquireList.locator(page.getByRole('listitem'))).toHaveText(
13+
['Report a crate that violates policies'].concat(['For all other cases']),
14+
);
1315

1416
await percy.snapshot();
1517
await a11y.audit();
@@ -23,7 +25,9 @@ test.describe('Acceptance | support page', { tag: '@acceptance' }, () => {
2325
await expect(page.getByTestId('inquire-list-section')).toBeVisible();
2426
const inquireList = page.getByTestId('inquire-list');
2527
await expect(inquireList).toBeVisible();
26-
await expect(inquireList.locator(page.getByRole('listitem'))).toHaveText(['Report a crate that violates policies']);
28+
await expect(inquireList.locator(page.getByRole('listitem'))).toHaveText(
29+
['Report a crate that violates policies'].concat(['For all other cases']),
30+
);
2731
});
2832

2933
test.describe('reporting a crate from support page', () => {

tests/acceptance/support-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ module('Acceptance | support', function (hooks) {
2424
const listitem = findAll('[data-test-id="inquire-list"] li');
2525
assert.deepEqual(
2626
listitem.map(item => item.textContent.trim()),
27-
['Report a crate that violates policies'],
27+
['Report a crate that violates policies'].concat(['For all other cases']),
2828
);
2929

3030
await percySnapshot(assert);
@@ -41,7 +41,7 @@ module('Acceptance | support', function (hooks) {
4141
const listitem = findAll('[data-test-id="inquire-list"] li');
4242
assert.deepEqual(
4343
listitem.map(item => item.textContent.trim()),
44-
['Report a crate that violates policies'],
44+
['Report a crate that violates policies'].concat(['For all other cases']),
4545
);
4646
});
4747

0 commit comments

Comments
 (0)