Commit 8849c291 authored by Mathieu Giraud's avatar Mathieu Giraud
Browse files

Merge branch 'feature-c/5013-reset-le-provider-imgt-si-on-change-de-primerset' into 'dev'

[VW] Resolve "reset le provider imgt si on change de primerset"

Closes #5013

See merge request !1176
parents 875d50b4 8c63697b
Pipeline #512325 failed with stages
in 13 minutes and 25 seconds
......@@ -156,6 +156,7 @@ LAYERS = {
'className': "seq_layer_underline",
'style': { 'background': "#484" },
'refresh': function(c){ if (typeof c.seg.imgt == 'undefined') return "IMGT"},
'reset': function(c){ delete c.seg.imgt },
'enabled': true,
},
......
......@@ -151,6 +151,17 @@ Model.prototype = {
check.checked = self.trimming_before_external
console.default.log( self.trimming_before_external )
}
// get list of layers to reset
for (var l in LAYERS){
if (LAYERS[l].reset != undefined){
for (var c_id in self.clones){
LAYERS[l].reset(self.clones[c_id])
}
}
}
self.update()
})
......
......@@ -222,6 +222,42 @@ describe('External Aligner', function () {
return
})
it('Aligner external provider reset if trimming', function() {
cy.openAnalysis("doc/analysis-example2.vidjil", "doc/analysis-example2.analysis")
cy.get('#polyline0').click()
cy.get('#align-refresh-button')
.should("be.visible")
// before calling provider
cy.get('#align-refresh-button > span > .icon-arrows-ccw')
.should("exist")
cy.get("#icon_external_IMGT")
.should("have.class", "icon-arrows-ccw")
cy.get('#toIMGTseg').click({force:true})
cy.get('.identityBad')
.should("be.visible")
cy.get('#align-refresh-button > span > i')
.should("have.class", "icon-ok")
cy.get("#primerEcngs").click({force:true})
cy.get("#remove_primer_external").click({force:true})
// after trimming call
cy.get('#align-refresh-button > span > .icon-arrows-ccw')
.should("exist")
cy.get("#icon_external_IMGT")
.should("have.class", "icon-arrows-ccw")
return
})
it('Aligner external provider - Get Correct Videntity', function() {
// Use ins/del event if available
cy.openAnalysis("data/demo_lil_l3_tutorial.vidjil")
......@@ -237,7 +273,6 @@ describe('External Aligner', function () {
cy.get("#icon_external_IMGT")
.should("have.class", "icon-arrows-ccw")
cy.get('#align-refresh-button > span > .icon-arrows-ccw')
.click({force:true})
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment