chore(repo): add packages to e2e-release and explicit error for flakiness (#20740)
This commit is contained in:
parent
dba679ec47
commit
a30888b92e
@ -49,6 +49,7 @@ describe('nx release - independent projects', () => {
|
|||||||
beforeAll(() => {
|
beforeAll(() => {
|
||||||
newProject({
|
newProject({
|
||||||
unsetProjectNameAndRootFormat: false,
|
unsetProjectNameAndRootFormat: false,
|
||||||
|
packages: ['@nx/js'],
|
||||||
});
|
});
|
||||||
|
|
||||||
pkg1 = uniq('my-pkg-1');
|
pkg1 = uniq('my-pkg-1');
|
||||||
|
|||||||
@ -48,6 +48,7 @@ describe('nx release - private JS packages', () => {
|
|||||||
beforeAll(() => {
|
beforeAll(() => {
|
||||||
newProject({
|
newProject({
|
||||||
unsetProjectNameAndRootFormat: false,
|
unsetProjectNameAndRootFormat: false,
|
||||||
|
packages: ['@nx/js'],
|
||||||
});
|
});
|
||||||
|
|
||||||
publicPkg1 = uniq('public-pkg-1');
|
publicPkg1 = uniq('public-pkg-1');
|
||||||
|
|||||||
@ -50,6 +50,7 @@ describe('nx release', () => {
|
|||||||
beforeAll(() => {
|
beforeAll(() => {
|
||||||
newProject({
|
newProject({
|
||||||
unsetProjectNameAndRootFormat: false,
|
unsetProjectNameAndRootFormat: false,
|
||||||
|
packages: ['@nx/js'],
|
||||||
});
|
});
|
||||||
|
|
||||||
pkg1 = uniq('my-pkg-1');
|
pkg1 = uniq('my-pkg-1');
|
||||||
@ -111,11 +112,26 @@ describe('nx release', () => {
|
|||||||
).toEqual(3);
|
).toEqual(3);
|
||||||
|
|
||||||
// Only one dependency relationship exists, so this log should only match once
|
// Only one dependency relationship exists, so this log should only match once
|
||||||
expect(
|
const dependencyRelationshipLogMatch = versionOutput.match(
|
||||||
versionOutput.match(
|
/Applying new version 999.9.9 to 1 package which depends on my-pkg-\d*/g
|
||||||
/Applying new version 999.9.9 to 1 package which depends on my-pkg-\d*/g
|
);
|
||||||
).length
|
if (
|
||||||
).toEqual(1);
|
!dependencyRelationshipLogMatch ||
|
||||||
|
dependencyRelationshipLogMatch.length !== 1
|
||||||
|
) {
|
||||||
|
// From JamesHenry: explicit error to assist troubleshooting NXC-143
|
||||||
|
throw new Error(
|
||||||
|
`
|
||||||
|
Error: Expected to find exactly one dependency relationship log line.
|
||||||
|
|
||||||
|
If you are seeing this message then you have been impacted by some currently undiagnosed flakiness in the test.
|
||||||
|
|
||||||
|
Please report the full nx release version command output below to the Nx team:
|
||||||
|
|
||||||
|
${versionOutput}`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
expect(dependencyRelationshipLogMatch.length).toEqual(1);
|
||||||
|
|
||||||
// Generate a changelog for the new version
|
// Generate a changelog for the new version
|
||||||
expect(exists('CHANGELOG.md')).toEqual(false);
|
expect(exists('CHANGELOG.md')).toEqual(false);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user