Commit 9af97a34 authored by Jacques Erasmus's avatar Jacques Erasmus

Update master to main

Updated master to main
parent 0c171090
......@@ -17,7 +17,7 @@ const projectRefsEndpoint = '/root/project/refs';
const pipelinesPath = '/root/project/-/pipelines';
const configVariablesPath = '/root/project/-/pipelines/config_variables';
const newPipelinePostResponse = { id: 1 };
const defaultBranch = 'master';
const defaultBranch = 'main';
describe('Pipeline New Form', () => {
let wrapper;
......@@ -187,13 +187,13 @@ describe('Pipeline New Form', () => {
await waitForPromises();
});
it('variables persist between ref changes', async () => {
selectBranch('master');
selectBranch('main');
await waitForPromises();
const masterInput = findKeyInputs().at(0);
masterInput.element.value = 'build_var';
masterInput.trigger('change');
const mainInput = findKeyInputs().at(0);
mainInput.element.value = 'build_var';
mainInput.trigger('change');
await wrapper.vm.$nextTick();
......@@ -207,7 +207,7 @@ describe('Pipeline New Form', () => {
await wrapper.vm.$nextTick();
selectBranch('master');
selectBranch('main');
await waitForPromises();
......
......@@ -10,8 +10,8 @@ import RefsDropdown from '~/pipeline_new/components/refs_dropdown.vue';
import { mockRefs, mockFilteredRefs } from '../mock_data';
const projectRefsEndpoint = '/root/project/refs';
const refShortName = 'master';
const refFullName = 'refs/heads/master';
const refShortName = 'main';
const refFullName = 'refs/heads/main';
jest.mock('~/flash');
......
export const mockRefs = {
Branches: ['master', 'branch-1', 'branch-2'],
Branches: ['main', 'branch-1', 'branch-2'],
Tags: ['1.0.0', '1.1.0', '1.2.0'],
};
......@@ -40,6 +40,6 @@ export const mockError = {
total_warnings: 7,
};
export const mockBranchRefs = ['master', 'dev', 'release'];
export const mockBranchRefs = ['main', 'dev', 'release'];
export const mockTagRefs = ['1.0.0', '1.1.0', '1.2.0'];
......@@ -5,7 +5,7 @@ import { mockBranchRefs, mockTagRefs } from '../mock_data';
describe('Format refs util', () => {
it('formats branch ref correctly', () => {
expect(formatRefs(mockBranchRefs, BRANCH_REF_TYPE)).toEqual([
{ fullName: 'refs/heads/master', shortName: 'master' },
{ fullName: 'refs/heads/main', shortName: 'main' },
{ fullName: 'refs/heads/dev', shortName: 'dev' },
{ fullName: 'refs/heads/release', shortName: 'release' },
]);
......
......@@ -138,7 +138,7 @@ describe('Pipelines filtered search', () => {
describe('Url query params', () => {
const params = {
username: 'deja.green',
ref: 'master',
ref: 'main',
};
beforeEach(() => {
......
......@@ -3727,8 +3727,8 @@ export default {
scheduled_actions: [],
},
ref: {
name: 'master',
path: '/h5bp/html5-boilerplate/commits/master',
name: 'main',
path: '/h5bp/html5-boilerplate/commits/main',
tag: false,
branch: true,
merge_request: false,
......
......@@ -221,22 +221,22 @@ export default {
cancelable: false,
},
ref: {
name: 'master',
path: '/root/ci-mock/tree/master',
name: 'main',
path: '/root/ci-mock/tree/main',
tag: false,
branch: true,
},
commit: {
id: '798e5f902592192afaba73f4668ae30e56eae492',
short_id: '798e5f90',
title: "Merge branch 'new-branch' into 'master'\r",
title: "Merge branch 'new-branch' into 'main'\r",
created_at: '2017-04-13T10:25:17.000+01:00',
parent_ids: [
'54d483b1ed156fbbf618886ddf7ab023e24f8738',
'c8e2d38a6c538822e81c57022a6e3a0cfedebbcc',
],
message:
"Merge branch 'new-branch' into 'master'\r\n\r\nAdd new file\r\n\r\nSee merge request !1",
"Merge branch 'new-branch' into 'main'\r\n\r\nAdd new file\r\n\r\nSee merge request !1",
author_name: 'Root',
author_email: 'admin@example.com',
authored_date: '2017-04-13T10:25:17.000+01:00',
......
......@@ -387,7 +387,7 @@ export const tags = [
protected: false,
},
{
name: 'master-tag',
name: 'main-tag',
message: '',
target: '66673b07efef254dab7d537f0433a40e61cf84fe',
commit: {
......@@ -413,10 +413,10 @@ export const tags = [
export const mockSearch = [
{ type: 'username', value: { data: 'root', operator: '=' } },
{ type: 'ref', value: { data: 'master', operator: '=' } },
{ type: 'ref', value: { data: 'main', operator: '=' } },
{ type: 'status', value: { data: 'pending', operator: '=' } },
];
export const mockBranchesAfterMap = ['branch-1', 'branch-10', 'branch-11'];
export const mockTagsAfterMap = ['tag-3', 'tag-2', 'tag-1', 'master-tag'];
export const mockTagsAfterMap = ['tag-3', 'tag-2', 'tag-1', 'main-tag'];
......@@ -2,7 +2,7 @@ import { shallowMount } from '@vue/test-utils';
import ExperimentTracking from '~/experimentation/experiment_tracking';
import PipelinesCiTemplate from '~/pipelines/components/pipelines_list/pipelines_ci_templates.vue';
const addCiYmlPath = "/-/new/master?commit_message='Add%20.gitlab-ci.yml'";
const addCiYmlPath = "/-/new/main?commit_message='Add%20.gitlab-ci.yml'";
const suggestedCiTemplates = [
{ name: 'Android', logo: '/assets/illustrations/logos/android.svg' },
{ name: 'Bash', logo: '/assets/illustrations/logos/bash.svg' },
......
......@@ -289,7 +289,7 @@ describe('Pipelines', () => {
page: '1',
scope: 'all',
username: 'root',
ref: 'master',
ref: 'main',
status: 'pending',
};
......@@ -321,7 +321,7 @@ describe('Pipelines', () => {
expect(window.history.pushState).toHaveBeenCalledWith(
expect.anything(),
expect.anything(),
`${window.location.pathname}?page=1&scope=all&username=root&ref=master&status=pending`,
`${window.location.pathname}?page=1&scope=all&username=root&ref=main&status=pending`,
);
});
});
......
......@@ -13,7 +13,7 @@ describe('Test case details', () => {
formattedTime: '10.04ms',
recent_failures: {
count: 2,
base_branch: 'master',
base_branch: 'main',
},
system_output: 'Line 42 is broken',
};
......
......@@ -89,7 +89,7 @@ describe('Pipeline Branch Name Token', () => {
});
it('renders only the branch searched for', () => {
const mockBranches = ['master'];
const mockBranches = ['main'];
createComponent({ stubs }, { branches: mockBranches, loading: false });
expect(findAllFilteredSearchSuggestions()).toHaveLength(mockBranches.length);
......
......@@ -89,7 +89,7 @@ describe('Pipeline Branch Name Token', () => {
});
it('renders only the tag searched for', () => {
const mockTags = ['master-tag'];
const mockTags = ['main-tag'];
createComponent({ stubs }, { tags: mockTags, loading: false });
expect(findAllFilteredSearchSuggestions()).toHaveLength(mockTags.length);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment