Skip to content

Commit ccaa2cb

Browse files
committed
udpate testing files
1 parent 9d5d3c2 commit ccaa2cb

File tree

4 files changed

+32
-9
lines changed

4 files changed

+32
-9
lines changed

src/test/resources/cgds-h2.sql

+4-4
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ CREATE TABLE `mutation_event` (
448448
`KEYWORD` varchar(255) DEFAULT NULL COMMENT 'e.g. truncating, V200 Missense, E338del, ',
449449
KEY (`KEYWORD`),
450450
PRIMARY KEY (`MUTATION_EVENT_ID`),
451-
-- Line removed for H2 compatibility : KEY `KEY_MUTATION_EVENT_DETAILS` (`CHR`, `START_POSITION`, `END_POSITION`, `TUMOR_SEQ_ALLELE`(240), `ENTREZ_GENE_ID`, `PROTEIN_CHANGE`, `MUTATION_TYPE`),
451+
KEY `KEY_MUTATION_EVENT_DETAILS` (`CHR`, `START_POSITION`, `END_POSITION`, `TUMOR_SEQ_ALLELE`(240), `ENTREZ_GENE_ID`, `PROTEIN_CHANGE`, `MUTATION_TYPE`),
452452
FOREIGN KEY (`ENTREZ_GENE_ID`) REFERENCES `gene` (`ENTREZ_GENE_ID`),
453453
INDEX (`MUTATION_TYPE`)
454454
) COMMENT='Mutation Data';
@@ -648,7 +648,7 @@ CREATE TABLE `cosmic_mutation` (
648648

649649
-- --------------------------------------------------------
650650
CREATE TABLE `clinical_event` (
651-
`CLINICAL_EVENT_ID` int NOT NULL auto_increment,
651+
`CLINICAL_EVENT_ID` BIGINT NOT NULL auto_increment,
652652
`PATIENT_ID` int(11) NOT NULL,
653653
`START_DATE` int NOT NULL,
654654
`STOP_DATE` int,
@@ -660,7 +660,7 @@ CREATE TABLE `clinical_event` (
660660

661661
-- --------------------------------------------------------
662662
CREATE TABLE `clinical_event_data` (
663-
`CLINICAL_EVENT_ID` int(255) NOT NULL,
663+
`CLINICAL_EVENT_ID` BIGINT NOT NULL,
664664
`KEY` varchar(255) NOT NULL,
665665
`VALUE` varchar(5000) NOT NULL,
666666
FOREIGN KEY (`CLINICAL_EVENT_ID`) REFERENCES `clinical_event` (`CLINICAL_EVENT_ID`) ON DELETE CASCADE
@@ -753,5 +753,5 @@ CREATE TABLE `resource_study` (
753753
);
754754

755755
-- THIS MUST BE KEPT IN SYNC WITH db.version PROPERTY IN pom.xml
756-
INSERT INTO info VALUES ('2.13.1', NULL);
756+
INSERT INTO info VALUES ('2.14.0', NULL);
757757

src/test/resources/cgds.sql

+3-3
Original file line numberDiff line numberDiff line change
@@ -648,7 +648,7 @@ CREATE TABLE `cosmic_mutation` (
648648

649649
-- --------------------------------------------------------
650650
CREATE TABLE `clinical_event` (
651-
`CLINICAL_EVENT_ID` int NOT NULL auto_increment,
651+
`CLINICAL_EVENT_ID` BIGINT NOT NULL auto_increment,
652652
`PATIENT_ID` int(11) NOT NULL,
653653
`START_DATE` int NOT NULL,
654654
`STOP_DATE` int,
@@ -660,7 +660,7 @@ CREATE TABLE `clinical_event` (
660660

661661
-- --------------------------------------------------------
662662
CREATE TABLE `clinical_event_data` (
663-
`CLINICAL_EVENT_ID` int(255) NOT NULL,
663+
`CLINICAL_EVENT_ID` BIGINT NOT NULL,
664664
`KEY` varchar(255) NOT NULL,
665665
`VALUE` varchar(5000) NOT NULL,
666666
FOREIGN KEY (`CLINICAL_EVENT_ID`) REFERENCES `clinical_event` (`CLINICAL_EVENT_ID`) ON DELETE CASCADE
@@ -753,5 +753,5 @@ CREATE TABLE `resource_study` (
753753
);
754754

755755
-- THIS MUST BE KEPT IN SYNC WITH db.version PROPERTY IN pom.xml
756-
INSERT INTO info VALUES ('2.13.1', NULL);
756+
INSERT INTO info VALUES ('2.14.0', NULL);
757757

test/integration/test_load_study.sh

+13-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,18 @@ run_in_service cbioportal 'validateData.py -v -p /cbioportal/portalinfo -s /cbio
3030

3131
# load study_es_0 using API validation
3232
echo "Testing loading of study with API validation..."
33-
run_in_service cbioportal 'metaImport.py -v -u http://cbioportal-container:8080 -o -s /cbioportal/test/test_data/study_es_0/'
33+
run_in_service cbioportal '
34+
# Update the JAR file
35+
cd core
36+
jar -xf core-1.0.9.jar scripts/ requirements.txt
37+
chmod -R a+x scripts/
38+
jar xf core-1.0.9.jar META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
39+
sed -i "s/db.version=2.13.1/db.version=2.14.0/" META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
40+
jar uf core-1.0.9.jar META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
41+
rm -rf META-INF
42+
cd ..
3443
44+
# Run the import
45+
metaImport.py -v -u http://cbioportal-container:8080 -o -s /cbioportal/test/test_data/study_es_0/
46+
'
3547
exit 0

test/integration/test_update_oncokb.sh

+12-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,18 @@ run_in_service() {
1212

1313
# load study_es_0 using API validation
1414
echo "Testing update of OncoKB annotations..."
15-
run_in_service cbioportal 'metaImport.py -v -u http://cbioportal-container:8080 -o -s /cbioportal/test/test_data/study_oncokb_update/'
15+
run_in_service cbioportal '
16+
# Update the JAR file
17+
cd core
18+
jar -xf core-1.0.9.jar scripts/ requirements.txt
19+
chmod -R a+x scripts/
20+
jar xf core-1.0.9.jar META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
21+
sed -i "s/db.version=2.13.1/db.version=2.14.0/" META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
22+
jar uf core-1.0.9.jar META-INF/maven/org.cbioportal/cbioportal-core/pom.properties
23+
rm -rf META-INF
24+
cd ..
25+
26+
metaImport.py -v -u http://cbioportal-container:8080 -o -s /cbioportal/test/test_data/study_oncokb_update/'
1627

1728
# execute updateOncokb script
1829
run_in_service cbioportal 'python3 /core/scripts/importer/updateOncokbAnnotations.py -s study_es_0 -p /cbioportal-webapp/application.properties'

0 commit comments

Comments
 (0)