yarn build and adapt e2e tests
Co-Authored-By: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>


@@ -101,7 +101,7 @@ describe('Flowchart v2', () => {
|
||||
const style = svg.attr('style');
|
||||
expect(style).to.match(/^max-width: [\d.]+px;$/);
|
||||
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
|
||||
expect(maxWidthValue).to.be.within(300 * .95-1, 300 * 1.05);
|
||||
expect(maxWidthValue).to.be.within(290 * .95-1, 290 * 1.05);
|
||||
});
|
||||
});
|
||||
it('8: should render a flowchart when useMaxWidth is false', () => {
|
||||
@@ -121,7 +121,7 @@ describe('Flowchart v2', () => {
|
||||
const width = parseFloat(svg.attr('width'));
|
||||
// use within because the absolute value can be slightly different depending on the environment ±5%
|
||||
expect(height).to.be.within(446 * .95, 446 * 1.05);
|
||||
expect(width).to.be.within(300 * .95-1, 300 * 1.05);
|
||||
expect(width).to.be.within(290 * .95-1, 290 * 1.05);
|
||||
expect(svg).to.not.have.attr('style');
|
||||
});
|
||||
});
|
||||
|
@@ -584,7 +584,7 @@ context('Sequence diagram', () => {
|
||||
expect(svg).to.have.attr('width', '100%');
|
||||
expect(svg).to.have.attr('height');
|
||||
const height = parseFloat(svg.attr('height'));
|
||||
expect(height).to.eq(920);
|
||||
expect(height).to.be.within(920, 960);
|
||||
const style = svg.attr('style');
|
||||
expect(style).to.match(/^max-width: [\d.]+px;$/);
|
||||
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
|
||||
@@ -624,7 +624,7 @@ context('Sequence diagram', () => {
|
||||
.should((svg) => {
|
||||
const height = parseFloat(svg.attr('height'));
|
||||
const width = parseFloat(svg.attr('width'));
|
||||
expect(height).to.eq(920);
|
||||
expect(height).to.be.within(920, 960);
|
||||
// use within because the absolute value can be slightly different depending on the environment ±5%
|
||||
expect(width).to.be.within(820 * .95, 820 * 1.05);
|
||||
expect(svg).to.not.have.attr('style');
|
||||
|
@@ -452,7 +452,7 @@ stateDiagram-v2
|
||||
expect(svg).to.have.attr('width', '100%');
|
||||
expect(svg).to.have.attr('height');
|
||||
const height = parseFloat(svg.attr('height'));
|
||||
expect(height).to.eq(177);
|
||||
expect(height).to.be.within(177, 178);
|
||||
const style = svg.attr('style');
|
||||
expect(style).to.match(/^max-width: [\d.]+px;$/);
|
||||
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
|
||||
@@ -474,7 +474,7 @@ stateDiagram-v2
|
||||
.should((svg) => {
|
||||
const height = parseFloat(svg.attr('height'));
|
||||
const width = parseFloat(svg.attr('width'));
|
||||
expect(height).to.eq(177);
|
||||
expect(height).to.be.within(177, 178);
|
||||
// use within because the absolute value can be slightly different depending on the environment ±5%
|
||||
expect(width).to.be.within(135 * .95, 135 * 1.05);
|
||||
expect(svg).to.not.have.attr('style');
|
||||
|
Before Width: | Height: | Size: 235 KiB |
Before Width: | Height: | Size: 234 KiB |
Before Width: | Height: | Size: 240 KiB |
Before Width: | Height: | Size: 236 KiB |
Before Width: | Height: | Size: 247 KiB |
Before Width: | Height: | Size: 256 KiB |
Before Width: | Height: | Size: 255 KiB |
Before Width: | Height: | Size: 255 KiB |
Before Width: | Height: | Size: 155 KiB |
Before Width: | Height: | Size: 278 KiB |
Before Width: | Height: | Size: 325 KiB |
Before Width: | Height: | Size: 335 KiB |
Before Width: | Height: | Size: 323 KiB |
Before Width: | Height: | Size: 299 KiB |
Before Width: | Height: | Size: 286 KiB |