Skip to content

Commit d4c2007

Browse files
test: load 2d NMR binary files
1 parent 790b9a1 commit d4c2007

4 files changed

Lines changed: 12 additions & 2 deletions

File tree

public/data/COSY-12.zip

3.27 MB
Binary file not shown.

public/data/HMBC-13.zip

7.06 MB
Binary file not shown.

src/demo/NMRiumWrapperDemo.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,11 @@ export default function NMRiumWrapperDemo() {
7171
</Button.Done>
7272
<Button.Done
7373
onClick={async () => {
74-
const files = await loadFilesFromURLs(['../data/13c.zip']);
74+
const files = await loadFilesFromURLs([
75+
'../data/COSY-12.zip',
76+
'../data/HMBC-13.zip',
77+
'../data/13c.zip',
78+
]);
7579
events.trigger('load', {
7680
data: files,
7781
type: 'file',

test-e2e/core.test.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,13 @@ test('should load NMRium from Files', async ({ page }) => {
4747
// if loaded successfully, there should be a 1H and 13C tabs
4848
await test.step('spectra should be loaded', async () => {
4949
await expect(
50-
nmrium.page.locator('.tab-list-item >> text=13C'),
50+
page.locator('.tab-list-item').getByText('13C', { exact: true }),
51+
).toBeVisible();
52+
await expect(
53+
page.locator('.tab-list-item').getByText('1H,1H', { exact: true }),
54+
).toBeVisible();
55+
await expect(
56+
page.locator('.tab-list-item').getByText('1H,13C', { exact: true }),
5157
).toBeVisible();
5258
});
5359

0 commit comments

Comments
 (0)