Skip to content

Commit

Permalink
Bump 2.22 release version to public (#5391)
Browse files Browse the repository at this point in the history
---------

Co-authored-by: Roman Rodionov <roman_rodionov@epam.com>
  • Loading branch information
svvald and rrodionov91 authored Aug 30, 2024
1 parent 95d3f87 commit cbb61b9
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ test.describe('Indigo Tools - Calculate CIP Tool', () => {
});

test.afterEach(async ({ page }) => {
await takeEditorScreenshot(page);
await takeEditorScreenshot(page, { maxDiffPixels: 1 });
});

test('Operation with a structure without stereo properties', async ({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -580,14 +580,14 @@ test.describe('Templates - Functional Group Tools3', () => {
await page.getByPlaceholder('Search by elements...').click();
await page.keyboard.press('C');
await page.keyboard.press('2');
await takeEditorScreenshot(page);
await takeEditorScreenshot(page, { maxDiffPixels: 1 });

await page.getByRole('banner').getByRole('button').click();

await pressButton(page, STRUCTURE_LIBRARY_BUTTON_NAME);
await page.getByPlaceholder('Search by elements...').click();
await page.keyboard.press('Y');
await takeEditorScreenshot(page);
await takeEditorScreenshot(page, { maxDiffPixels: 1 });
});

test('Expand/Remove abbreviation context menu with selected tools', async ({
Expand Down
13 changes: 11 additions & 2 deletions ketcher-autotests/tests/utils/canvas/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -153,14 +153,19 @@ export async function screenshotDialog(page: Page, dialogId: string) {
export async function takeElementScreenshot(
page: Page,
elementId: string,
options?: { masks?: Locator[]; maxDiffPixelRatio?: number },
options?: {
masks?: Locator[];
maxDiffPixelRatio?: number;
maxDiffPixels?: number;
},
) {
const maxTimeout = 3000;
const element = page.getByTestId(elementId).first();
await waitForRender(page, emptyFunction, maxTimeout);
await expect(element).toHaveScreenshot({
mask: options?.masks,
maxDiffPixelRatio: options?.maxDiffPixelRatio,
maxDiffPixels: options?.maxDiffPixels,
});
}

Expand Down Expand Up @@ -225,7 +230,11 @@ export async function takeMonomerLibraryScreenshot(

export async function takeEditorScreenshot(
page: Page,
options?: { masks?: Locator[]; maxDiffPixelRatio?: number },
options?: {
masks?: Locator[];
maxDiffPixelRatio?: number;
maxDiffPixels: number;
},
) {
await takeElementScreenshot(page, 'ketcher-canvas', options);
}
Expand Down
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/ketcher-core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-core",
"version": "2.22.0-rc.9",
"version": "2.22.0",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
2 changes: 1 addition & 1 deletion packages/ketcher-macromolecules/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-macromolecules",
"version": "2.22.0-rc.9",
"version": "2.22.0",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
2 changes: 1 addition & 1 deletion packages/ketcher-react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-react",
"version": "2.22.0-rc.9",
"version": "2.22.0",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
4 changes: 2 additions & 2 deletions packages/ketcher-standalone/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-standalone",
"version": "2.22.0-rc.9",
"version": "2.22.0",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down Expand Up @@ -42,7 +42,7 @@
},
"dependencies": {
"@babel/runtime": "^7.17.9",
"indigo-ketcher": "1.21.0-rc.3",
"indigo-ketcher": "1.21.0",
"ketcher-core": "*"
},
"devDependencies": {
Expand Down

0 comments on commit cbb61b9

Please sign in to comment.