Project

General

Profile

« Previous | Next » 

Revision 29aeffbe

Added by Cherian Mathew almost 9 years ago

EditConceptRelationshipComposite : show notification only when creating concept relationship
NewTaxonBaseComposite : added second sec. combobox for the case of creating synonyms
INewTaxonBaseComponentListener, NewTaxonBasePresenter : creating separate containers for acc. taxon and synonym references
NewTaxonBasePresenter, NewTaxonBasePresenterTest : updated new synonym method to include acc. taxon sec in input
StatusComposite : added move / change actions to context menu

View differences:

src/test/java/eu/etaxonomy/cdm/vaadin/presenter/NewTaxonBasePresenterTest.java
53 53
    @Test
54 54
    public void testNewTaxonBase() throws SQLException {
55 55
        RowId refId20 = new RowId(20);
56
        RowId refId21 = new RowId(21);
56 57
        UUID newTaxonUuid = ntbp.newTaxon("Taxon E", refId20, UUID.fromString("6595638e-4993-421a-9fe5-76b09d94f36a")).getUuid();
57 58
        List<String> ACC_TAXON_INIT_STRATEGY = Arrays.asList(new String []{
59
                "sec",
58 60
                "synonymRelations"
59 61
        });
60 62
        Taxon taxon = CdmBase.deproxy(CdmSpringContextHelper.getTaxonService().load(newTaxonUuid,ACC_TAXON_INIT_STRATEGY),Taxon.class);
61 63

  
62
        UUID newSynonymUuid = ntbp.newSynonym("Synonym OfE", refId20, newTaxonUuid).getUuid();
64
        UUID newSynonymUuid = ntbp.newSynonym("Synonym OfE", refId20, refId21, newTaxonUuid).getUuid();
63 65
        taxon = CdmBase.deproxy(CdmSpringContextHelper.getTaxonService().load(newTaxonUuid,ACC_TAXON_INIT_STRATEGY),Taxon.class);
64 66

  
65 67
        Set<Synonym> synonyms = taxon.getSynonyms();
......
68 70

  
69 71
        Synonym synonym = CdmBase.deproxy(CdmSpringContextHelper.getTaxonService().load(newSynonymUuid),Synonym.class);
70 72
        Assert.assertEquals(synonym, synonymOfTaxon);
73

  
74
        Assert.assertEquals(synonym.getSec().getId(), 20);
75

  
76
        taxon = CdmBase.deproxy(CdmSpringContextHelper.getTaxonService().load(newTaxonUuid,ACC_TAXON_INIT_STRATEGY),Taxon.class);
77

  
78
        Assert.assertEquals(taxon.getSec().getId(), 21);
71 79
    }
72 80

  
73 81

  

Also available in: Unified diff