const ui = {
updateMessage: byRole('alert'),
openDialogBtn: byRole('button', { name: 'learn_more' }),
+ learnMoreLink: byRole('link', { name: /learn_more/ }),
dialog: byRole('dialog', { name: 'system.system_upgrade' }),
latestHeader: byRole('heading', { name: /system.latest_version/ }),
latestLTAHeader: byRole('heading', { name: /system.lta_version/ }),
`admin_notification.update.${UpdateUseCase.CurrentVersionInactive}`,
);
expect(ui.openDialogBtn.query()).not.toBeInTheDocument();
+ expect(ui.learnMoreLink.get()).toBeInTheDocument();
});
it('should not show the notification banner if there is no network connection and version has not reached the eol', () => {
`admin_notification.update.${UpdateUseCase.CurrentVersionInactive}`,
);
expect(ui.openDialogBtn.query()).not.toBeInTheDocument();
+ expect(ui.learnMoreLink.get()).toBeInTheDocument();
});
it('active / latest / patch', async () => {
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
+import { Link } from '@sonarsource/echoes-react';
import { ButtonSecondary } from 'design-system';
import * as React from 'react';
import { translate } from '../../helpers/l10n';
}, [setSystemUpgradeFormOpen]);
if (systemUpgrades.length === 0) {
- return null;
+ return (
+ <Link
+ className="sw-ml-2"
+ to="https://www.sonarsource.com/products/sonarqube/downloads/?referrer=sonarqube"
+ target="_blank"
+ >
+ {translate('learn_more')}
+ </Link>
+ );
}
return (
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
-import { addMonths, formatISO } from 'date-fns';
import { omit } from 'lodash';
import { To } from 'react-router-dom';
import { CompareResponse } from '../api/quality-profiles';
qualifiers: [ComponentQualifier.Project],
settings: {},
version: '1.0',
- versionEOL: formatISO(addMonths(new Date(), 1), { representation: 'date' }),
+ versionEOL: '2020-01-01',
documentationUrl: 'https://docs.sonarsource.com/sonarqube/10.0',
...overrides,
};