Skip to content

Commit

Permalink
Merge pull request #1163 from cBioPortal/release-1.13.0
Browse files Browse the repository at this point in the history
Release 1.13.0
  • Loading branch information
inodb authored May 10, 2018
2 parents 5bd9a3e + 5beacf4 commit 8826743
Show file tree
Hide file tree
Showing 78 changed files with 2,820 additions and 903 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
181 changes: 172 additions & 9 deletions end-to-end-tests/specs/home.spec.js

Large diffs are not rendered by default.

28 changes: 28 additions & 0 deletions end-to-end-tests/specs/screenshot.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,27 @@ describe('result page screenshot tests', function(){
});

describe("oncoprint screenshot tests", function() {
it("coadread_tcga_pub with clinical and heatmap tracks", ()=>{
var url = `${CBIOPORTAL_URL}/index.do?cancer_study_id=coadread_tcga_pub&Z_SCORE_THRESHOLD=1&RPPA_SCORE_THRESHOLD=2&data_priority=0&case_set_id=coadread_tcga_pub_nonhypermut&gene_list=KRAS%20NRAS%20BRAF&geneset_list=%20&tab_index=tab_visualize&Action=Submit&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=coadread_tcga_pub_mutations&genetic_profile_ids_PROFILE_COPY_NUMBER_ALTERATION=coadread_tcga_pub_gistic&genetic_profile_ids_PROFILE_MRNA_EXPRESSION=coadread_tcga_pub_rna_seq_mrna_median_Zscores&show_samples=false&clinicallist=0%2C2%2CMETHYLATION_SUBTYPE&heatmap_track_groups=coadread_tcga_pub_rna_seq_mrna_median_Zscores%2CKRAS%2CNRAS%2CBRAF&`;
goToUrlAndSetLocalStorage(url);
waitForOncoprint(10000);
var res = browser.checkElement('#oncoprint');
assertScreenShotMatch(res);
});
it("acc_tcga with clinical and heatmap tracks", ()=>{
var url = `${CBIOPORTAL_URL}/index.do?cancer_study_id=acc_tcga&Z_SCORE_THRESHOLD=1&RPPA_SCORE_THRESHOLD=1&data_priority=0&case_set_id=acc_tcga_all&gene_list=SOX9%20RAN%20TNK2%20EP300%20PXN%20NCOA2%20AR%20NRIP1%20NCOR1%20NCOR2&geneset_list=%20&tab_index=tab_visualize&Action=Submit&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=acc_tcga_mutations&genetic_profile_ids_PROFILE_COPY_NUMBER_ALTERATION=acc_tcga_gistic&genetic_profile_ids_PROFILE_MRNA_EXPRESSION=acc_tcga_rna_seq_v2_mrna_median_Zscores&genetic_profile_ids_PROFILE_PROTEIN_EXPRESSION=acc_tcga_rppa_Zscores&show_samples=false&clinicallist=0%2C1%2CMETASTATIC_DX_CONFIRMED_BY&heatmap_track_groups=acc_tcga_rna_seq_v2_mrna_median_Zscores%2CSOX9%2CRAN%2CTNK2%2CEP300%2CPXN%2CNCOA2%2CAR%2CNRIP1%2CNCOR1%2CNCOR2`;
goToUrlAndSetLocalStorage(url);
waitForOncoprint(10000);
var res = browser.checkElement('#oncoprint');
assertScreenShotMatch(res);
});
it("blca_tcga with clinical and heatmap tracks", ()=>{
var url = `${CBIOPORTAL_URL}/index.do?cancer_study_id=blca_tcga_pub&Z_SCORE_THRESHOLD=1&RPPA_SCORE_THRESHOLD=1&data_priority=0&case_set_id=blca_tcga_pub_all&gene_list=SOX9%20RAN%20TNK2%20EP300%20PXN%20NCOA2%20AR%20NRIP1%20NCOR1%20NCOR2&geneset_list=%20&tab_index=tab_visualize&Action=Submit&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=blca_tcga_pub_mutations&genetic_profile_ids_PROFILE_COPY_NUMBER_ALTERATION=blca_tcga_pub_gistic&genetic_profile_ids_PROFILE_MRNA_EXPRESSION=blca_tcga_pub_rna_seq_mrna_median_Zscores&genetic_profile_ids_PROFILE_PROTEIN_EXPRESSION=blca_tcga_pub_rppa_Zscores&show_samples=false&heatmap_track_groups=blca_tcga_pub_rna_seq_mrna_median_Zscores%2CSOX9%2CRAN%2CTNK2%2CEP300%2CPXN%2CNCOA2%2CAR%2CNRIP1%2CNCOR1%2CNCOR2&clinicallist=CANCER_TYPE_DETAILED%2CMETASTATIC_SITE_OTHER%2CNEW_TUMOR_EVENT_AFTER_INITIAL_TREATMENT`;
goToUrlAndSetLocalStorage(url);
waitForOncoprint(10000);
var res = browser.checkElement('#oncoprint');
assertScreenShotMatch(res);
});
it("hcc_inserm_fr_2015 with genes including TERT - it should show orange promoter mutations in TERT", function() {
goToUrlAndSetLocalStorage(`${CBIOPORTAL_URL}/index.do?cancer_study_id=hcc_inserm_fr_2015&Z_SCORE_THRESHOLD=2.0&RPPA_SCORE_THRESHOLD=2.0&data_priority=0&case_set_id=hcc_inserm_fr_2015_sequenced&gene_list=SOX9%2520RAN%2520TNK2%2520EP300%2520PXN%2520NCOA2%2520AR%2520NRIP1%2520NCOR1%2520NCOR2%2520TERT&geneset_list=+&tab_index=tab_visualize&Action=Submit&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=hcc_inserm_fr_2015_mutations`);
waitForOncoprint(20000);
Expand Down Expand Up @@ -121,6 +142,13 @@ describe("oncoprint screenshot tests", function() {
var res = browser.checkElement("#oncoprint");
assertScreenShotMatch(res);
});
it("brca_tcga_pub with KRAS NRAS BRAF and methylation heatmap tracks", function() {
var url = `${CBIOPORTAL_URL}/index.do?cancer_study_id=brca_tcga_pub&Z_SCORE_THRESHOLD=2&RPPA_SCORE_THRESHOLD=2&data_priority=0&case_set_id=brca_tcga_pub_cnaseq&gene_list=KRAS%2520NRAS%2520BRAF&geneset_list=%20&tab_index=tab_visualize&Action=Submit&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=brca_tcga_pub_mutations&genetic_profile_ids_PROFILE_COPY_NUMBER_ALTERATION=brca_tcga_pub_gistic&show_samples=false&heatmap_track_groups=brca_tcga_pub_methylation_hm27%2CKRAS%2CNRAS%2CBRAF%2CTP53%2CBRCA1%2CBRCA2`;
goToUrlAndSetLocalStorage(url);
waitForOncoprint(10000);
var res = browser.checkElement("#oncoprint");
assertScreenShotMatch(res);
});
});

describe("download tab screenshot tests", function() {
Expand Down
4 changes: 2 additions & 2 deletions env/rc.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export CBIOPORTAL_URL="http://www.cbioportal.org/beta"
export GENOME_NEXUS_URL="https://genomenexus-rc.herokuapp.com"
export CBIOPORTAL_URL="http://www.cbioportal.org/rc"
export GENOME_NEXUS_URL="https://www.genomenexus.org"
File renamed without changes.
18 changes: 9 additions & 9 deletions package-lock.json

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

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"@types/js-combinatorics": "0.5.29",
"@types/jspdf": "^1.1.31",
"@types/jstree": "^3.3.35",
"@types/lodash": "4.14.66",
"@types/lodash": "^4.14.104",
"@types/lolex": "1.5.31",
"@types/mocha": "2.2.41",
"@types/pdfobject": "2.0.5",
Expand Down Expand Up @@ -204,7 +204,7 @@
"swagger-client": "^2.1.32",
"swagger-js-codegen": "git+https://github.com/cBioPortal/swagger-js-codegen.git#77031560146c6985c99cd40eda208b04052ab631",
"ts-loader": "^2.0.0",
"typescript": "^2.6.2",
"typescript": "^2.7.2",
"underscore": "^1.8.3",
"universal-ga": "^1.2.0",
"url": "^0.11.0",
Expand Down
5 changes: 5 additions & 0 deletions src/globalComponents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import QueryAndDownloadTabs from "./shared/components/query/QueryAndDownloadTabs
import {QueryStore} from "./shared/components/query/QueryStore";
import formSubmit from "shared/lib/formSubmit";
import {getStudySummaryUrl} from "./shared/api/urls";
import {genes} from "shared/lib/oql/oqlfilter.js"

class GlobalStores {

Expand All @@ -13,8 +14,12 @@ class GlobalStores {
}

}
(window as any).frontendVars = {};

(window as any).getStudySummaryUrl = getStudySummaryUrl;
(window as any).frontendVars.oqlGenes = (oqlQuery:string)=>{
return genes(oqlQuery);
};

exposeComponentRenderer('renderRightBar', ()=> {
return <RightBar store={GlobalStores.queryStore} />;
Expand Down
2 changes: 1 addition & 1 deletion src/pages/patientView/sampleManager.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export function sortSamples(samples: Array<ClinicalDataBySampleId>,

sampleOrder = _.orderBy(sampleOrder, ['eventOrdering', 'sampleTypeIndex', 'naturalSortIndex'], ['asc','asc','asc']);
let sampleOrderMap = _.fromPairs(sampleOrder.map((so, i) => [so.id, i]));
return _.sortBy(samples, (sample) => {
return _.sortBy<ClinicalDataBySampleId>(samples, (sample) => {
return sampleOrderMap[sample.id];
});
}
Expand Down
24 changes: 19 additions & 5 deletions src/pages/resultsView/ResultsViewPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import OverlappingStudiesWarning from "../../shared/components/overlappingStudie
import CNSegments from "./cnSegments/CNSegments";
import './styles.scss';
import {genes} from "shared/lib/oql/oqlfilter.js";
import oql_parser from "shared/lib/oql/oql-parser.js";

(Chart as any).plugins.register({
beforeDraw: function(chartInstance:any) {
Expand All @@ -49,7 +50,7 @@ function initStore(queryStore: QueryStore) {

const oqlQuery = serverVars.theQuery;

const parsedOQL = (window as any).oql_parser.parse(oqlQuery);
const parsedOQL = oql_parser.parse(oqlQuery);

const genesetIds = (serverVars.genesetIds.length
? serverVars.genesetIds.split(/\s+/)
Expand Down Expand Up @@ -103,6 +104,7 @@ function initStore(queryStore: QueryStore) {
resultsViewPageStore.zScoreThreshold = serverVars.zScoreThreshold;
resultsViewPageStore.oqlQuery = oqlQuery;
resultsViewPageStore.queryStore = queryStore;
resultsViewPageStore.cohortIdsList = serverVars.cohortIdsList;

return resultsViewPageStore;

Expand Down Expand Up @@ -143,17 +145,29 @@ export default class ResultsViewPage extends React.Component<IResultsViewPagePro

// hide mutex tab
$(document).ready(()=>{
if (genes((window as any).serverVars.theQuery).length <= 1) {
if (!(window as any).serverVars.theQuery.trim().length || genes((window as any).serverVars.theQuery).length <= 1) {
$('a#mutex-result-tab').parent().hide();
}
//hide gene-specific tabs when we only query gene sets (and no genes are queried)
// TODO: this should probably be changed once we have single page
// app
if (!(window as any).serverVars.theQuery.trim().length || genes((window as any).serverVars.theQuery).length == 0) {
$('a#cancer-types-result-tab').parent().hide();
$('a#plots-result-tab').parent().hide();
$('a#mutation-result-tab').parent().hide();
$('a#coexp-result-tab').parent().hide();
$('a#enrichments-result-tab').parent().hide();
$('a#survival-result-tab').parent().hide();
$('a#network-result-tab').parent().hide();
$('a#igv-result-tab').parent().hide();
$('a#data-download-result-tab').parent().hide();
}

if (win.cancerStudyIdList !== 'null') {
getGAInstance().event('results view', 'show', { eventLabel: win.cancerStudyIdList });
} else if (_.includes(['all','null'],win.cancerStudyId) === false) {
getGAInstance().event('results view', 'show', { eventLabel: win.cancerStudyId });
}


});
}

Expand Down Expand Up @@ -272,7 +286,7 @@ export default class ResultsViewPage extends React.Component<IResultsViewPagePro
samplesExtendedWithClinicalData={this.resultsViewPageStore.samplesExtendedWithClinicalData.result!}
alterationsByGeneBySampleKey={this.resultsViewPageStore.alterationsByGeneBySampleKey.result!}
studies={this.resultsViewPageStore.studies.result!}
studyMap={this.resultsViewPageStore.studyMap}
studyMap={this.resultsViewPageStore.physicalStudySet}
/>
</div>)
} else if (isPending) {
Expand Down
Loading

0 comments on commit 8826743

Please sign in to comment.