@@ -0,0 +1,1645 @@
+package org.jboss.da.test.server.listings;%0A%0Aimport org.jboss.arquillian.junit.Arquillian;%0Aimport org.jboss.da.communication.auth.impl.JAASAuthenticatorService;%0Aimport org.jboss.da.listings.api.model.ProductVersion;%0Aimport org.jboss.da.listings.api.service.ArtifactService.ArtifactStatus;%0Aimport org.jboss.da.listings.api.service.ProductService;%0Aimport org.jboss.da.listings.api.service.ProductVersionService;%0Aimport org.jboss.da.listings.api.service.WhiteArtifactService;%0Aimport org.jboss.da.listings.model.ProductSupportStatus;%0Aimport org.jboss.da.test.server.AbstractServerTest;%0Aimport static org.junit.Assert.assertEquals;%0Aimport org.junit.Test;%0Aimport org.junit.runner.RunWith;%0A%0Aimport javax.inject.Inject;%0A%0A/**%0A *%0A * @author Honza Br%C3%A1zdil %3Cjaninko.g@gmail.com%3E%0A */%0A@RunWith(Arquillian.class)%0Apublic class WhiteArtifactServiceTest extends AbstractServerTest %7B%0A%0A    @Inject%0A    ProductVersionService pvs;%0A%0A    @Inject%0A    ProductService ps;%0A%0A    @Inject%0A    WhiteArtifactService was;%0A%0A    @Test%0A    public void testAddDuplicateGA() %7B%0A        JAASAuthenticatorService.setUser(%22user%22);%0A        ps.addProduct(%22EAP%22, %229.4.6%22, ProductSupportStatus.UNKNOWN);%0A        ProductVersion pv = pvs.getProductVersion(%22EAP%22, %229.4.6%22).get();%0A        ArtifactStatus ret1 = was.addArtifact(%22foo%22, %22bar%22, %221.0.0%22, pv.getId());%0A        assertEquals(ArtifactStatus.ADDED, ret1);%0A        ArtifactStatus ret2 = was.addArtifact(%22foo%22, %22bar%22, %221.0.0%22, pv.getId());%0A        assertEquals(ArtifactStatus.NOT_MODIFIED, ret2);%0A        ArtifactStatus ret3 = was.addArtifact(%22foo%22, %22bar%22, %222.0.0%22, pv.getId());%0A        assertEquals(ArtifactStatus.GA_EXISTS, ret3);%0A    %7D%0A%0A%7D%0A

Add reproducer test