From 5e30e5f0a37c5b0e79a7cea1a4d01648d50b065e Mon Sep 17 00:00:00 2001 From: rmanaem Date: Wed, 25 Oct 2023 14:58:07 -0400 Subject: [PATCH] Replaced all references of `Subject ID` with `Participant ID` --- README.md | 4 +-- components/next-page.vue | 2 +- cypress/component/category-select-table.cy.js | 6 ++-- cypress/component/column-linking-table.cy.js | 6 ++-- cypress/e2e/app/simple-e2etest.cy.js | 12 +++---- cypress/e2e/page/annotation-pagetests.cy.js | 6 ++-- .../e2e/page/categorization-pagetests.cy.js | 36 +++++++++---------- .../store-getter-getAnnotationComponent.cy.js | 2 +- ...store-mutation-updateAnnotationCount.cy.js | 2 +- 9 files changed, 38 insertions(+), 38 deletions(-) diff --git a/README.md b/README.md index 6b885199..8e68b996 100644 --- a/README.md +++ b/README.md @@ -126,7 +126,7 @@ _Next page criteria:_ A `participants.tsv` file must be uploaded to proceed to c ### Categorization page -The Categorization page is where you link the columns in your data table to the categories found in Neurobagel's metadata schema. Current categories include 'Subject ID', 'Age', 'Sex' and 'Diagnosis'. Aside from the 'Subject ID' which is a special case, categories represent different data types, 'Sex' and 'Diagnosis' are categorical while 'Age' is continuous. +The Categorization page is where you link the columns in your data table to the categories found in Neurobagel's metadata schema. Current categories include 'Participant ID', 'Age', 'Sex' and 'Diagnosis'. Aside from the 'Participant ID' which is a special case, categories represent different data types, 'Sex' and 'Diagnosis' are categorical while 'Age' is continuous. ![Home page with uploaded table and dictionary files](./images/readme_categorization_page.png) @@ -135,7 +135,7 @@ The Categorization page is where you link the columns in your data table to the 1. Select a category in the category selection component on the left. 2. Select a column from your uploaded `participants.tsv` in the table on the right. (Its description from your `participants.json` - if uploaded - will be seen here as well.) This will paint the column's table row with the same color as the category you have selected. This column is now linked to that category and you will be able to annotate its values on the annotation page. -_Next page criteria:_ A column must be annotated as holding a 'Subject ID', and at least one other column must be linked with one of the other categories +_Next page criteria:_ A column must be annotated as holding a 'Participant ID', and at least one other column must be linked with one of the other categories ### Annotation page diff --git a/components/next-page.vue b/components/next-page.vue index 7d59deb3..c7e56ac6 100644 --- a/components/next-page.vue +++ b/components/next-page.vue @@ -57,7 +57,7 @@ instructions: { "home": "", - "categorization": "One column must be categorized as 'Subject ID' and all assessment tools must be grouped to proceed", + "categorization": "One column must be categorized as 'Participant ID' and all assessment tools must be grouped to proceed", "annotation": "" } } diff --git a/cypress/component/category-select-table.cy.js b/cypress/component/category-select-table.cy.js index daa97a21..5f7453d2 100644 --- a/cypress/component/category-select-table.cy.js +++ b/cypress/component/category-select-table.cy.js @@ -8,7 +8,7 @@ const computed = { return [ - "Subject ID", + "Participant ID", "Age", "Sex", "Diagnosis", @@ -23,7 +23,7 @@ const computed = { categoryClasses: { - "Subject ID": "category-style-1", + "Participant ID": "category-style-1", "Age": "category-style-2", "Sex": "category-style-3", "Diagnosis": "category-style-4", @@ -35,7 +35,7 @@ const computed = { const categoryColorMap = { - "Subject ID": "rgb(164, 208, 90)", + "Participant ID": "rgb(164, 208, 90)", "Age": "rgb(127, 23, 167)", "Sex": "rgb(70, 76, 174)", "Diagnosis": "rgb(236, 197, 50)", diff --git a/cypress/component/column-linking-table.cy.js b/cypress/component/column-linking-table.cy.js index c172a5eb..cfb4bbcc 100644 --- a/cypress/component/column-linking-table.cy.js +++ b/cypress/component/column-linking-table.cy.js @@ -25,7 +25,7 @@ describe("The column-linking-table component", () => { return [ - "Subject ID", + "Participant ID", "Age", "Sex", "Diagnosis", @@ -69,7 +69,7 @@ describe("The column-linking-table component", () => { categoryClasses: { - "Subject ID": "category-style-1", + "Participant ID": "category-style-1", "Age": "category-style-2", "Sex": "category-style-3", "Diagnosis": "category-style-4", @@ -88,7 +88,7 @@ describe("The column-linking-table component", () => { props = { - selectedCategory: "Subject ID" + selectedCategory: "Participant ID" }; }); diff --git a/cypress/e2e/app/simple-e2etest.cy.js b/cypress/e2e/app/simple-e2etest.cy.js index 45bd30b2..c1a73eb9 100644 --- a/cypress/e2e/app/simple-e2etest.cy.js +++ b/cypress/e2e/app/simple-e2etest.cy.js @@ -32,7 +32,7 @@ describe("End to end test using a simple UI path through the app", () => { categories: [ - ["Subject ID", 1], + ["Participant ID", 1], ["Age", 1] ] }; @@ -62,23 +62,23 @@ describe("End to end test using a simple UI path through the app", () => { if ( cy.datasetMeetsTestCriteria("categorization", p_dataset, testCriteria) ) { - // 2. Go through categorization page, categorizing subject ID and age columns in the table + // 2. Go through categorization page, categorizing Participant ID and age columns in the table // A. Assert nav and next button are not yet be enabled cy.assertNextPageAccess("annotation", false); - // B. Categorize "participant_id" as "Subject ID" - cy.categorizeColumn("Subject ID", p_dataset["category_columns"]["Subject ID"][0]); + // B. Categorize "participant_id" as "Participant ID" + cy.categorizeColumn("Participant ID", p_dataset["category_columns"]["Participant ID"][0]); // C. Assert nav and next button are not yet enabled - // For annotation page to be enabled, subject ID and + // For annotation page to be enabled, Participant ID and // at least one other column must be categorized. cy.assertNextPageAccess("annotation", false); // D. Categorize "age" as "Age" cy.categorizeColumn("Age", p_dataset["category_columns"]["Age"][0]); - // Since Age and subject ID have been categorized + // Since Age and Participant ID have been categorized // annotation page is no accessible. cy.assertNextPageAccess("annotation", true); diff --git a/cypress/e2e/page/annotation-pagetests.cy.js b/cypress/e2e/page/annotation-pagetests.cy.js index 75e0199b..ac18557f 100644 --- a/cypress/e2e/page/annotation-pagetests.cy.js +++ b/cypress/e2e/page/annotation-pagetests.cy.js @@ -56,7 +56,7 @@ describe("tests on annotation page ui with programmatic state loading and store categories: [ - ["Subject ID", 1], + ["Participant ID", 1], ["Age", 1] ] }; @@ -96,7 +96,7 @@ describe("tests on annotation page ui with programmatic state loading and store categories: [ - ["Subject ID", 1], + ["Participant ID", 1], ["Sex", 1] ] }; @@ -139,7 +139,7 @@ describe("tests on annotation page ui with programmatic state loading and store categories: [ - ["Subject ID", 1], + ["Participant ID", 1], ["Diagnosis", 1] ] }; diff --git a/cypress/e2e/page/categorization-pagetests.cy.js b/cypress/e2e/page/categorization-pagetests.cy.js index 936c04cc..27e62af1 100644 --- a/cypress/e2e/page/categorization-pagetests.cy.js +++ b/cypress/e2e/page/categorization-pagetests.cy.js @@ -46,17 +46,17 @@ describe("Tests on categorization page ui via programmatic state loading and sto }); // Description of task: - // 1. Selects 'Subject ID' category - // 2. Links one column as containing subject ID + // 1. Selects 'Participant ID' category + // 2. Links one column as containing Participant ID // Expected results: Annotation nav and Next page button are enabled - it("Single column categorization; categorize subject ID", () => { + it("Single column categorization; categorize Participant ID", () => { // 0. Categories required for this test and the number of required columns for each category const testCriteria = { categories: [ - ["Subject ID", 1] + ["Participant ID", 1] ] }; @@ -65,8 +65,8 @@ describe("Tests on categorization page ui via programmatic state loading and sto // 1. Assert annotation nav and next page button are disabled cy.assertNextPageAccess("annotation", false); - // 2. Categorize first subject id column in table as 'Subject ID' - cy.categorizeColumn("Subject ID", p_dataset["category_columns"]["Subject ID"][0]); + // 2. Categorize first participant id column in table as 'Participant ID' + cy.categorizeColumn("Participant ID", p_dataset["category_columns"]["Participant ID"][0]); // 3. Assert that annotation nav and next page button are disabled cy.assertNextPageAccess("annotation", false); @@ -74,18 +74,18 @@ describe("Tests on categorization page ui via programmatic state loading and sto }); // Description of task: - // 1. Selects 'Subject ID' category + 'Age' category - // 2. Links one column as a subject ID + // 1. Selects 'Participant ID' category + 'Age' category + // 2. Links one column as a Participant ID // 3. Links another column as age // Expected results: Annotation nav and Next page button are enabled - it("Multiple column categorization; categorize subject ID and age", () => { + it("Multiple column categorization; categorize participant ID and age", () => { // 0. Categories required for this test and the number of required columns for each category const testCriteria = { categories: [ - ["Subject ID", 1], + ["Participant ID", 1], ["Age", 1] ] }; @@ -95,8 +95,8 @@ describe("Tests on categorization page ui via programmatic state loading and sto // 1. Assert annotation nav and next page button are disabled cy.assertNextPageAccess("annotation", false); - // 2. Categorize a column in the table as 'Subject ID' - cy.categorizeColumn("Subject ID", p_dataset["category_columns"]["Subject ID"][0]); + // 2. Categorize a column in the table as 'Participant ID' + cy.categorizeColumn("Participant ID", p_dataset["category_columns"]["Participant ID"][0]); // 3. Categorize a column in the table as 'Age' cy.categorizeColumn("Age", p_dataset["category_columns"]["Age"][0]); @@ -107,29 +107,29 @@ describe("Tests on categorization page ui via programmatic state loading and sto }); // Description of task: - // 1. Selects 'Subject ID' category - // 2. Links one column as a subject ID + // 1. Selects 'Participant ID' category + // 2. Links one column as a Participant ID // Expected results: Color of linked column changes it("Make sure the color changes after clicking", () => { cy.get("[data-cy='column-linking-table'] tbody > tr") - .contains(p_dataset["category_columns"]["Subject ID"][0]) + .contains(p_dataset["category_columns"]["Participant ID"][0]) .parent() .invoke("css", "background-color") .then((p_oldColor) => { // Act - // 1. Categorize a row in the column linking table with 'Subject ID' category from + // 1. Categorize a row in the column linking table with 'Participant ID' category from // the category select table - cy.categorizeColumn("Subject ID", p_dataset["category_columns"]["Subject ID"][0]); + cy.categorizeColumn("Participant ID", p_dataset["category_columns"]["Participant ID"][0]); // Assert // 2. Check that the new color of the categorized row is different than its previous // background color cy.get("[data-cy='column-linking-table'] tbody > tr") - .contains(p_dataset["category_columns"]["Subject ID"][0]) + .contains(p_dataset["category_columns"]["Participant ID"][0]) .parent() .should("not.have.css", "background-color", p_oldColor); }); diff --git a/cypress/unit/store-getter-getAnnotationComponent.cy.js b/cypress/unit/store-getter-getAnnotationComponent.cy.js index 0e51f7f1..a52a9e23 100644 --- a/cypress/unit/store-getter-getAnnotationComponent.cy.js +++ b/cypress/unit/store-getter-getAnnotationComponent.cy.js @@ -12,7 +12,7 @@ describe("The getAnnotationComponent getter", () => { categories: { - "Subject ID": {}, + "Participant ID": {}, "Age": { componentName: "annot-continuous-values" diff --git a/cypress/unit/store-mutation-updateAnnotationCount.cy.js b/cypress/unit/store-mutation-updateAnnotationCount.cy.js index 13d68230..d512d259 100644 --- a/cypress/unit/store-mutation-updateAnnotationCount.cy.js +++ b/cypress/unit/store-mutation-updateAnnotationCount.cy.js @@ -13,7 +13,7 @@ describe("updateAnnotationCount", () => { categories: { - "Subject ID": {}, + "Participant ID": {}, "Age": { componentName: "annot-continuous-values" }, "Sex": { componentName: "annot-categorical" }, "Diagnosis": { componentName: "annot-categorical" }