Sfoglia il codice sorgente

Fixes from review

tags/8.0
Jeremy Davis 4 anni fa
parent
commit
81516c0b3c

+ 2
- 2
server/sonar-web/src/main/js/apps/projectBaseline/__tests__/__snapshots__/BranchList-test.tsx.snap Vedi File

@@ -11,14 +11,14 @@ exports[`should render correctly 1`] = `
branch_list.branch
</th>
<th
className="thin nowrap huge-spacer-right"
className="nowrap huge-spacer-right"
>
branch_list.current_setting
</th>
<th
className="thin nowrap"
>
branch_list.edit_settings
branch_list.actions
</th>
</tr>
</thead>

+ 2
- 2
server/sonar-web/src/main/js/apps/projectBaseline/components/BranchList.tsx Vedi File

@@ -168,10 +168,10 @@ export default class BranchList extends React.PureComponent<Props, State> {
<thead>
<tr>
<th>{translate('branch_list.branch')}</th>
<th className="thin nowrap huge-spacer-right">
<th className="nowrap huge-spacer-right">
{translate('branch_list.current_setting')}
</th>
<th className="thin nowrap">{translate('branch_list.edit_settings')}</th>
<th className="thin nowrap">{translate('branch_list.actions')}</th>
</tr>
</thead>
<tbody>

+ 4
- 4
server/sonar-web/src/main/js/helpers/__tests__/periods-test.ts Vedi File

@@ -85,17 +85,17 @@ describe('getPeriodLabel', () => {

it('should handle SPECIFIC_ANALYSIS', () => {
expect(
getPeriodLabel(mockPeriod({ mode: 'SPECIFIC_ANALYSIS', modeParam: 'A658678DE' }), formatter)
).toBe('overview.period.specific_analysis.A658678DE');
getPeriodLabel(mockPeriod({ mode: 'SPECIFIC_ANALYSIS', parameter: '7.1' }), formatter)
).toBe('overview.period.specific_analysis.2019-04-23T02:12:32+0100');
expect(getPeriodLabel(mockPeriod({ mode: 'SPECIFIC_ANALYSIS' }), formatter)).toBe(
'overview.period.specific_analysis.2019-04-23T02:12:32+0100'
);
expect(formatter).toBeCalledTimes(1);
expect(formatter).toBeCalledTimes(2);
});

it('should handle PREVIOUS_VERSION', () => {
expect(
getPeriodLabel(mockPeriod({ mode: 'PREVIOUS_VERSION', parameter: 'A658678DE' }), formatter)
getPeriodLabel(mockPeriod({ mode: 'PREVIOUS_VERSION', modeParam: 'A658678DE' }), formatter)
).toBe('overview.period.previous_version.A658678DE');
expect(getPeriodLabel(mockPeriod({ mode: 'PREVIOUS_VERSION' }), formatter)).toBe(
'overview.period.previous_version.2019-04-23T02:12:32+0100'

+ 1
- 1
server/sonar-web/src/main/js/helpers/periods.ts Vedi File

@@ -43,7 +43,7 @@ export function getPeriodLabel(

switch (period.mode) {
case 'SPECIFIC_ANALYSIS':
parameter = parameter || dateFormatter(period.date);
parameter = dateFormatter(period.date);
break;
case 'PREVIOUS_VERSION':
parameter = parameter || dateFormatter(period.date);

+ 4
- 4
sonar-core/src/main/resources/org/sonar/l10n/core.properties Vedi File

@@ -551,7 +551,7 @@ project_baseline.configure_branches=Set a specific setting for a branch
baseline.previous_version=Previous version
baseline.previous_version.description=The New Code Period will begin with the analysis following the previous version.
baseline.number_days=Number of days
baseline.number_days.description=Specify a number of days to set a floating New Code Period window.
baseline.number_days.description=A floating New Code Period window set to a specific number of days.
baseline.specific_date=Specific date
baseline.specific_date.description=Set a specific date as the start of the New Code Period. (First analysis on this date will be used)
baseline.specific_analysis=Specific analysis
@@ -562,9 +562,9 @@ baseline.last_analysis_before=Last analysis before
baseline.next_analysis_notice=Changes will take effect after the next analysis

branch_list.branch=Branch
branch_list.current_setting=Current setting
branch_list.current_setting=Setting
branch_list.current_baseline=Current Baseline
branch_list.edit_settings=Edit settings
branch_list.actions=Actions
branch_list.default_setting=Project setting

baseline.new_code_period_for_branch_x=New Code Period for {0}
@@ -2565,7 +2565,7 @@ overview.period.manual_baseline=since {0}

# New periods (MMF-1579)
overview.period.number_of_days=from last {0} days
overview.period.specific_analysis=since analysis on {0}
overview.period.specific_analysis=since {0}

overview.gate.ERROR=Failed
overview.gate.WARN=Warning

Loading…
Annulla
Salva