From 8d9c3f7613b06fa4fa173c5502f270f6e260a680 Mon Sep 17 00:00:00 2001 From: "Marecor M. Baclay" Date: Fri, 19 Mar 2010 09:13:31 +0000 Subject: [PATCH] - modified the scripts to use a property file(testng.properties) for dotnet artifact's groupId, artifactId and version git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@925149 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/test/resources/testng.properties | 4 ++++ .../archiva/web/test/ArtifactManagementTest.java | 12 ++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/archiva-modules/archiva-web/archiva-webapp-test/src/test/resources/testng.properties b/archiva-modules/archiva-web/archiva-webapp-test/src/test/resources/testng.properties index aba24b4da..b7b268e19 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test/src/test/resources/testng.properties +++ b/archiva-modules/archiva-web/archiva-webapp-test/src/test/resources/testng.properties @@ -85,6 +85,10 @@ PACKAGING1=jar ARTIFACTFILEPATH1=test REPOSITORYID1=internal +GROUPID_DOTNETARTIFACT=dotNetTypes +ARTIFACTID_DOTNETARTIFACT=dotNetTypes +PACKAGING_DOTNETARTIFACT=library + SNAPSHOT_GROUPID=org.apache.archiva SNAPSHOT_ARTIFACTID=archiva-test SNAPSHOT_VERSION=1.0-SNAPSHOT diff --git a/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/ArtifactManagementTest.java b/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/ArtifactManagementTest.java index 58d2554c3..9a96246e5 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/ArtifactManagementTest.java +++ b/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/ArtifactManagementTest.java @@ -96,15 +96,19 @@ public class ArtifactManagementTest @Test( groups = "requiresUpload" ) public void testDotNetTypes() { - addArtifact( "dotNetTypes", "dotNetTypes", getVersion(), "library", getArtifactFilePath(), + String groupId = getProperty( "GROUPID_DOTNETARTIFACT" ); + String artifactId = getProperty( "ARTIFACTID_DOTNETARTIFACT" ); + String packaging = getProperty ( "PACKAGING_DOTNETARTIFACT" ); + + addArtifact( groupId, artifactId, getVersion(), packaging, getArtifactFilePath(), getRepositoryId() ); - assertTextPresent( "Artifact 'dotNetTypes:dotNetTypes:1.0' was successfully deployed to repository 'internal'" ); - getSelenium().open( baseUrl + "/browse/" + "dotNetTypes" + "/dotNetTypes/" + getVersion() ); + assertTextPresent( "Artifact '" + groupId + ":" + artifactId + ":" + getVersion() + "' was successfully deployed to repository 'internal'" ); + getSelenium().open( baseUrl + "/browse/" + groupId + "/" + artifactId + "/" + getVersion() ); waitPage(); assertTextPresent( "library" ); String basePath = - "/archiva/repository/internal/" + "dotNetTypes" + "/dotNetTypes/" + getVersion() + "/dotNetTypes-" + + "/archiva/repository/internal/" + groupId + "/" + artifactId + "/" + getVersion() + "/dotNetTypes-" + getVersion(); assertLinkPresent( ".NET Library" ); assertElementPresent( "//a[@href='" + basePath + ".dll']" ); -- 2.39.5