Rename GitHub product (#20347)
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: GitHub.com
|
title: GitHub
|
||||||
redirect_from:
|
redirect_from:
|
||||||
- /articles/
|
- /articles/
|
||||||
- /common-issues-and-questions/
|
- /common-issues-and-questions/
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ describe('breadcrumbs', () => {
|
|||||||
const $breadcrumbs = $('.breadcrumbs a')
|
const $breadcrumbs = $('.breadcrumbs a')
|
||||||
|
|
||||||
expect($breadcrumbs).toHaveLength(4)
|
expect($breadcrumbs).toHaveLength(4)
|
||||||
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub.com')
|
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub')
|
||||||
expect($breadcrumbs[1].attribs.title).toBe('category: Authentication')
|
expect($breadcrumbs[1].attribs.title).toBe('category: Authentication')
|
||||||
expect($breadcrumbs[2].attribs.title).toBe('mapTopic: Troubleshooting SSH')
|
expect($breadcrumbs[2].attribs.title).toBe('mapTopic: Troubleshooting SSH')
|
||||||
expect($breadcrumbs[3].attribs.title).toBe('article: Use SSH over HTTPS port')
|
expect($breadcrumbs[3].attribs.title).toBe('article: Use SSH over HTTPS port')
|
||||||
@@ -33,7 +33,7 @@ describe('breadcrumbs', () => {
|
|||||||
const $breadcrumbs = $('.breadcrumbs a')
|
const $breadcrumbs = $('.breadcrumbs a')
|
||||||
|
|
||||||
expect($breadcrumbs).toHaveLength(3)
|
expect($breadcrumbs).toHaveLength(3)
|
||||||
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub.com')
|
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub')
|
||||||
expect($breadcrumbs[1].attribs.title).toBe('category: Authentication')
|
expect($breadcrumbs[1].attribs.title).toBe('category: Authentication')
|
||||||
expect($breadcrumbs[2].attribs.title).toBe('mapTopic: Account security')
|
expect($breadcrumbs[2].attribs.title).toBe('mapTopic: Account security')
|
||||||
expect($breadcrumbs[2].attribs.class.includes('color-text-tertiary')).toBe(true)
|
expect($breadcrumbs[2].attribs.class.includes('color-text-tertiary')).toBe(true)
|
||||||
@@ -45,8 +45,7 @@ describe('breadcrumbs', () => {
|
|||||||
)
|
)
|
||||||
const $breadcrumbs = $('.breadcrumbs a')
|
const $breadcrumbs = $('.breadcrumbs a')
|
||||||
expect($breadcrumbs).toHaveLength(4)
|
expect($breadcrumbs).toHaveLength(4)
|
||||||
// The product is still GitHub.com on an Enterprise Server version
|
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub')
|
||||||
expect($breadcrumbs[0].attribs.title).toBe('product: GitHub.com')
|
|
||||||
})
|
})
|
||||||
|
|
||||||
test('parses Liquid variables inside titles', async () => {
|
test('parses Liquid variables inside titles', async () => {
|
||||||
@@ -85,7 +84,7 @@ describe('breadcrumbs', () => {
|
|||||||
expect($breadcrumbSpans).toHaveLength(2)
|
expect($breadcrumbSpans).toHaveLength(2)
|
||||||
expect($breadcrumbLinks).toHaveLength(2)
|
expect($breadcrumbLinks).toHaveLength(2)
|
||||||
expect($breadcrumbSpans[0].children[0].data).toBe('Early Access documentation')
|
expect($breadcrumbSpans[0].children[0].data).toBe('Early Access documentation')
|
||||||
expect($breadcrumbSpans[1].children[0].data).toBe('GitHub.com')
|
expect($breadcrumbSpans[1].children[0].data).toBe('GitHub')
|
||||||
expect($breadcrumbLinks[0].attribs.title).toBe(
|
expect($breadcrumbLinks[0].attribs.title).toBe(
|
||||||
'category: Enforcing best practices with GitHub Policies'
|
'category: Enforcing best practices with GitHub Policies'
|
||||||
)
|
)
|
||||||
@@ -101,7 +100,7 @@ describe('breadcrumbs', () => {
|
|||||||
{
|
{
|
||||||
documentType: 'product',
|
documentType: 'product',
|
||||||
href: '/en/github',
|
href: '/en/github',
|
||||||
title: 'GitHub.com',
|
title: 'GitHub',
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
expect(breadcrumbs).toEqual(expected)
|
expect(breadcrumbs).toEqual(expected)
|
||||||
@@ -113,7 +112,7 @@ describe('breadcrumbs', () => {
|
|||||||
{
|
{
|
||||||
documentType: 'product',
|
documentType: 'product',
|
||||||
href: '/en/github',
|
href: '/en/github',
|
||||||
title: 'GitHub.com',
|
title: 'GitHub',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
documentType: 'category',
|
documentType: 'category',
|
||||||
@@ -132,7 +131,7 @@ describe('breadcrumbs', () => {
|
|||||||
{
|
{
|
||||||
documentType: 'product',
|
documentType: 'product',
|
||||||
href: '/en/github',
|
href: '/en/github',
|
||||||
title: 'GitHub.com',
|
title: 'GitHub',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
documentType: 'category',
|
documentType: 'category',
|
||||||
@@ -156,7 +155,7 @@ describe('breadcrumbs', () => {
|
|||||||
{
|
{
|
||||||
documentType: 'product',
|
documentType: 'product',
|
||||||
href: '/en/github',
|
href: '/en/github',
|
||||||
title: 'GitHub.com',
|
title: 'GitHub',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
documentType: 'category',
|
documentType: 'category',
|
||||||
@@ -185,7 +184,7 @@ describe('breadcrumbs', () => {
|
|||||||
{
|
{
|
||||||
documentType: 'product',
|
documentType: 'product',
|
||||||
href: '/en/github',
|
href: '/en/github',
|
||||||
title: 'GitHub.com',
|
title: 'GitHub',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
documentType: 'category',
|
documentType: 'category',
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ describe('header', () => {
|
|||||||
const $ = await getDOM('/en/articles/enabling-required-status-checks')
|
const $ = await getDOM('/en/articles/enabling-required-status-checks')
|
||||||
const github = $('#homepages a.active[href="/en/github"]')
|
const github = $('#homepages a.active[href="/en/github"]')
|
||||||
expect(github.length).toBe(1)
|
expect(github.length).toBe(1)
|
||||||
expect(github.text().trim()).toBe('GitHub.com')
|
expect(github.text().trim()).toBe('GitHub')
|
||||||
expect(github.attr('class').includes('active')).toBe(true)
|
expect(github.attr('class').includes('active')).toBe(true)
|
||||||
|
|
||||||
const ghe = $(`#homepages a[href="/en/enterprise-server@${latest}/admin"]`)
|
const ghe = $(`#homepages a[href="/en/enterprise-server@${latest}/admin"]`)
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ describe('sidebar', () => {
|
|||||||
|
|
||||||
test('highlights active product on GitHub pages', async () => {
|
test('highlights active product on GitHub pages', async () => {
|
||||||
expect($githubPage('.sidebar-products li.sidebar-product').length).toBe(1)
|
expect($githubPage('.sidebar-products li.sidebar-product').length).toBe(1)
|
||||||
expect($githubPage('.sidebar-products li.sidebar-product > a').text().trim()).toBe('GitHub.com')
|
expect($githubPage('.sidebar-products li.sidebar-product > a').text().trim()).toBe('GitHub')
|
||||||
})
|
})
|
||||||
|
|
||||||
test('includes links to external products like the CLI, Atom, Electron, and CodeQL', async () => {
|
test('includes links to external products like the CLI, Atom, Electron, and CodeQL', async () => {
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ describe('products module', () => {
|
|||||||
describe('mobile-only products nav', () => {
|
describe('mobile-only products nav', () => {
|
||||||
test('renders current product on various product pages for each product', async () => {
|
test('renders current product on various product pages for each product', async () => {
|
||||||
// Note the unversioned homepage at `/` does not have a product selected in the mobile dropdown
|
// Note the unversioned homepage at `/` does not have a product selected in the mobile dropdown
|
||||||
expect((await getDOM('/github'))('#current-product').text().trim()).toBe('GitHub.com')
|
expect((await getDOM('/github'))('#current-product').text().trim()).toBe('GitHub')
|
||||||
|
|
||||||
// Enterprise server
|
// Enterprise server
|
||||||
expect((await getDOM('/en/enterprise/admin'))('#current-product').text().trim()).toBe(
|
expect((await getDOM('/en/enterprise/admin'))('#current-product').text().trim()).toBe(
|
||||||
@@ -39,7 +39,7 @@ describe('mobile-only products nav', () => {
|
|||||||
)('#current-product')
|
)('#current-product')
|
||||||
.text()
|
.text()
|
||||||
.trim()
|
.trim()
|
||||||
).toBe('GitHub.com')
|
).toBe('GitHub')
|
||||||
|
|
||||||
expect((await getDOM('/desktop'))('#current-product').text().trim()).toBe('GitHub Desktop')
|
expect((await getDOM('/desktop'))('#current-product').text().trim()).toBe('GitHub Desktop')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user