Skip to content

Commit 58e159c

Browse files
authored
RELEASE 2025-10-07 (#2049)
## Description Short description of the pull request ## Motivation Background on use case, changes needed ## Fixes: Please provide a list of the fixes implemented in this PR * Items added ## Changes: Please provide a list of the changes implemented by this PR * changes made ## Tests included - [ ] Included for each change/fix? - [ ] Passing? (Merge will not be approved unless this is checked) ## Documentation - [ ] swagger documentation updated \[required\] - [ ] official documentation updated \[nice-to-have\] ### official documentation info If you have updated the official documentation, please provide PR # and URL of the pages where the updates are included ## Backend version - [ ] Does it require a specific version of the backend - which version of the backend is required:
2 parents f715ca0 + 94ad749 commit 58e159c

File tree

90 files changed

+1268
-720
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+1268
-720
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ jobs:
129129
uses: cypress-io/github-action@v6
130130
with:
131131
config-file: cypress.config.ts
132+
browser: chrome
132133
install-command: npm install --omit peer
133134
- name: docker logs
134135
if: ${{ failure() }}

CI/e2e/frontend.config.e2e.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@
244244
"metadataJsonView": "Metadata JsonView",
245245
"datasetName": "Dataset Name"
246246
},
247-
"proposalDefault": {
247+
"proposal": {
248248
"General Information": "Proposal Information",
249249
"Title": "Proposal Title",
250250
"Abstract": "Abstract",

cypress/e2e/datasets/datasets-general.cy.js

Lines changed: 75 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -231,37 +231,36 @@ describe("Datasets general", () => {
231231
},
232232
},
233233
isPublished: true,
234-
}).then(() => {
235-
cy.readFile("CI/e2e/frontend.config.e2e.json").then((baseConfig) => {
236-
const testConfig = {
237-
...baseConfig,
238-
defaultDatasetsListSettings: {
239-
...baseConfig.defaultDatasetsListSettings,
240-
conditions: [
241-
{
242-
condition: {
243-
lhs: "outgassing_values_after_1h",
244-
relation: "GREATER_THAN",
245-
rhs: 1,
246-
unit: "",
247-
unitsOptions: [
248-
"mbar l/s/cm^2",
249-
"Pa m^3/s/m^2",
250-
"bar m^3/s/m^2",
251-
],
252-
},
253-
enabled: false,
234+
});
235+
cy.readFile("CI/e2e/frontend.config.e2e.json").then((baseConfig) => {
236+
const testConfig = {
237+
...baseConfig,
238+
defaultDatasetsListSettings: {
239+
...baseConfig.defaultDatasetsListSettings,
240+
conditions: [
241+
{
242+
condition: {
243+
lhs: "outgassing_values_after_1h",
244+
relation: "GREATER_THAN",
245+
rhs: 1,
246+
unit: "",
247+
unitsOptions: [
248+
"mbar l/s/cm^2",
249+
"Pa m^3/s/m^2",
250+
"bar m^3/s/m^2",
251+
],
254252
},
255-
],
256-
},
257-
};
258-
259-
cy.intercept("GET", "**/admin/config", testConfig).as("getConfig");
260-
cy.visit("/datasets");
261-
cy.wait("@getConfig", { timeout: 20000 });
262-
cy.finishedLoading();
263-
});
253+
enabled: false,
254+
},
255+
],
256+
},
257+
};
258+
259+
cy.intercept("GET", "**/admin/config", testConfig).as("getConfig");
264260
});
261+
cy.visit("/datasets");
262+
cy.wait("@getConfig", { timeout: 20000 });
263+
cy.finishedLoading();
265264
});
266265

267266
it("should display limited options in units dropdown", () => {
@@ -298,22 +297,35 @@ describe("Datasets general", () => {
298297
...baseConfig,
299298
defaultDatasetsListSettings: {
300299
...baseConfig.defaultDatasetsListSettings,
301-
filters: [{ TypeFilter: true }, { TextFilter: true }],
300+
filters: [
301+
{
302+
key: "type",
303+
label: "Type",
304+
type: "multiSelect",
305+
description: "Filter by dataset type",
306+
enabled: true,
307+
},
308+
{
309+
key: "keywords",
310+
label: "Keyword",
311+
type: "multiSelect",
312+
description: "Filter by keywords in the dataset",
313+
enabled: false,
314+
},
315+
],
302316
},
303317
};
304318

305319
cy.intercept("GET", "**/admin/config", testConfig).as("getConfig");
306320
cy.visit("/datasets");
307-
cy.wait("@getConfig", { timeout: 10000 });
321+
cy.wait("@getConfig");
308322
cy.finishedLoading();
309323
});
310324
});
311325

312326
it("should automatically apply pre-configured filters from config", () => {
313327
cy.contains("Type").should("exist");
314328

315-
cy.get('[data-cy="text-search"]').should("exist");
316-
317329
cy.contains("Location").should("not.exist");
318330
cy.contains("Keyword").should("not.exist");
319331
});
@@ -329,38 +341,37 @@ describe("Datasets general", () => {
329341
extra_entry_end_time: { type: "number", value: 2, unit: "" },
330342
},
331343
isPublished: true,
332-
}).then(() => {
333-
cy.readFile("CI/e2e/frontend.config.e2e.json").then((baseConfig) => {
334-
const relationsToTest = [
335-
{ relation: "GREATER_THAN", rhs: 1 },
336-
{ relation: "LESS_THAN", rhs: 3 },
337-
{ relation: "EQUAL_TO_NUMERIC", rhs: 2 },
338-
{ relation: "GREATER_THAN_OR_EQUAL", rhs: 2 },
339-
{ relation: "LESS_THAN_OR_EQUAL", rhs: 2 },
340-
{ relation: "RANGE", rhs: [1, 3] },
341-
];
342-
const testConfig = {
343-
...baseConfig,
344-
defaultDatasetsListSettings: {
345-
...baseConfig.defaultDatasetsListSettings,
346-
conditions: relationsToTest.map(({ relation, rhs }) => ({
347-
condition: {
348-
lhs: "extra_entry_end_time",
349-
relation,
350-
rhs,
351-
unit: "",
352-
},
353-
enabled: true,
354-
})),
355-
},
356-
};
357-
358-
cy.intercept("GET", "**/admin/config", testConfig).as("getConfig");
359-
cy.visit("/datasets");
360-
cy.wait("@getConfig", { timeout: 20000 });
361-
cy.finishedLoading();
362-
});
363344
});
345+
346+
cy.readFile("CI/e2e/frontend.config.e2e.json").then((baseConfig) => {
347+
const relationsToTest = [
348+
{ relation: "GREATER_THAN", rhs: 1 },
349+
{ relation: "LESS_THAN", rhs: 3 },
350+
{ relation: "EQUAL_TO_NUMERIC", rhs: 2 },
351+
{ relation: "GREATER_THAN_OR_EQUAL", rhs: 2 },
352+
{ relation: "LESS_THAN_OR_EQUAL", rhs: 2 },
353+
{ relation: "RANGE", rhs: [1, 3] },
354+
];
355+
const testConfig = {
356+
...baseConfig,
357+
defaultDatasetsListSettings: {
358+
...baseConfig.defaultDatasetsListSettings,
359+
conditions: relationsToTest.map(({ relation, rhs }) => ({
360+
condition: {
361+
lhs: "extra_entry_end_time",
362+
relation,
363+
rhs,
364+
unit: "",
365+
},
366+
enabled: true,
367+
})),
368+
},
369+
};
370+
371+
cy.intercept("GET", "**/admin/config", testConfig).as("getConfig");
372+
});
373+
cy.visit("/datasets");
374+
cy.wait("@getConfig");
364375
});
365376

366377
it("should check if pre-configured conditions are applied", () => {

cypress/e2e/datasets/datasets-metadata.cy.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ describe("Datasets", () => {
403403
describe("Different metadata types", () => {
404404
it("should be able to add a metadata entry with type 'date'", () => {
405405
const newMetadataName = "Cypress dataset date metadata";
406-
const metaDataInvalidValue = "20";
406+
const metaDataInvalidValue = "20ab";
407407
const metadata = {
408408
value: "2025-03-05 10:48",
409409
name: "date_metadata",

cypress/e2e/instruments/instruments-general.cy.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ describe("Instruments general", () => {
132132
.first()
133133
.should("not.contain", newInstrument.name);
134134

135-
cy.get(".mat-sort-header-container").contains("Name").click();
135+
cy.get(".mat-sort-header-container").eq(1).click();
136136

137137
cy.get("mat-table mat-row").first().should("contain", newInstrument.name);
138138

cypress/e2e/mainPage/main-page.cy.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,6 @@ describe("Main Page", () => {
6767

6868
describe("Main page configuration as authenticated user", () => {
6969
it("should visit main page correctly configured", () => {
70-
const username = Cypress.env("username");
71-
const password = Cypress.env("password");
72-
7370
cy.visit("/");
7471
cy.finishedLoading();
7572

@@ -94,7 +91,7 @@ describe("Main Page", () => {
9491
"button.mat-mdc-menu-item:nth-child(2) > span:nth-child(2) > span:nth-child(1)",
9592
).should("contain", "Files");
9693

97-
cy.get("div.main-menu").click();
94+
cy.get("body").type("{esc}");
9895

9996
cy.get('[data-cy="login-button"]').should("not.exist");
10097
cy.get(".user-button").should("exist");

cypress/e2e/proposals/proposals-general.cy.js

Lines changed: 4 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -463,31 +463,12 @@ describe("Proposals general", () => {
463463
cy.get("dynamic-mat-table")
464464
.scrollTo("right", { ensureScrollable: false })
465465
.get("mat-header-row")
466-
.should("contain", "First Name");
467-
468-
cy.get("dynamic-mat-table")
469-
.scrollTo("right", { ensureScrollable: false })
470-
.get("mat-header-row")
471-
.should("contain", "Last Name");
466+
.should("contain", "PI Last Name");
472467

473468
cy.get("dynamic-mat-table table-menu button").click();
474469

475470
cy.get('[role="menu"] button').contains("Column setting").click();
476-
cy.get('[role="menu"]')
477-
.contains("First Name")
478-
.parent()
479-
.find("input[type=checkbox]")
480-
.uncheck();
481-
cy.get('[role="menu"]')
482-
.contains("Last Name")
483-
.parent()
484-
.find("input[type=checkbox]")
485-
.uncheck();
486-
cy.get('[role="menu"]')
487-
.contains("PI First Name")
488-
.parent()
489-
.find("input[type=checkbox]")
490-
.uncheck();
471+
491472
cy.get('[role="menu"]')
492473
.contains("PI Last Name")
493474
.parent()
@@ -508,12 +489,7 @@ describe("Proposals general", () => {
508489
cy.get("dynamic-mat-table")
509490
.scrollTo("right", { ensureScrollable: false })
510491
.get("mat-header-row")
511-
.should("not.contain", "First Name");
512-
513-
cy.get("dynamic-mat-table")
514-
.scrollTo("right", { ensureScrollable: false })
515-
.get("mat-header-row")
516-
.should("not.contain", "Last Name");
492+
.should("not.contain", "PI Last Name");
517493

518494
cy.get("dynamic-mat-table table-menu button").click();
519495
cy.get('[role="menu"] button').contains("Default setting").click();
@@ -530,12 +506,7 @@ describe("Proposals general", () => {
530506
cy.get("dynamic-mat-table")
531507
.scrollTo("right", { ensureScrollable: false })
532508
.get("mat-header-row")
533-
.should("contain", "First Name");
534-
535-
cy.get("dynamic-mat-table")
536-
.scrollTo("right", { ensureScrollable: false })
537-
.get("mat-header-row")
538-
.should("contain", "Last Name");
509+
.should("contain", "PI Last Name");
539510
});
540511

541512
it("should be able to download table data as a json", () => {

cypress/e2e/published-data/published-data.cy.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,10 @@ describe("Datasets general", () => {
140140

141141
cy.isLoading();
142142

143-
cy.get(".dataset-table mat-row input[type='checkbox']").last().click();
143+
cy.get(".dataset-table mat-row input[type='checkbox']")
144+
.last()
145+
.and("not.be.disabled")
146+
.click();
144147

145148
cy.get("#addToBatchButton").click();
146149

cypress/fixtures/testData.js

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,12 +271,51 @@ export const testConfig = {
271271
},
272272
proposalViewCustomLabels: {
273273
labelsLocalization: {
274-
proposalDefault: {
274+
proposal: {
275275
"General Information": "Test Proposal Information",
276276
Title: "Test Proposal Title",
277277
Abstract: "Test Abstract",
278+
proposalId: "Proposal ID",
278279
"Proposal Id": "Test Proposal Id",
280+
firstname: "First Name",
281+
lastname: "Last Name",
282+
pi_firstname: "PI First Name",
283+
pi_lastname: "PI Last Name",
279284
},
280285
},
286+
defaultProposalsListSettings: {
287+
columns: [
288+
{
289+
name: "proposalId",
290+
width: 140,
291+
enabled: true,
292+
},
293+
{
294+
name: "title",
295+
width: 300,
296+
enabled: true,
297+
},
298+
{
299+
name: "startTime",
300+
format: "yyyy-MM-dd",
301+
type: "date",
302+
width: 200,
303+
enabled: true,
304+
},
305+
{
306+
name: "abstract",
307+
width: 140,
308+
type: "hoverContent",
309+
enabled: true,
310+
},
311+
{
312+
name: "pi_lastname",
313+
width: 300,
314+
enabled: true,
315+
},
316+
],
317+
filters: [],
318+
conditions: [],
319+
},
281320
},
282321
};

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)