diff --git a/cmd/create_srpm_test.go b/cmd/create_srpm_test.go index fa14be7..576f645 100644 --- a/cmd/create_srpm_test.go +++ b/cmd/create_srpm_test.go @@ -35,13 +35,15 @@ func testCreateSrpm(t *testing.T, t.Logf("DestDir: %s", destDir) testutil.SetupViperConfig( - "", // srcDir - workingDir, destDir, - "", // depsDir - "", // repoHost, - "", // dnfConfigFile - "", // srcRepoHost - "", // srcConfigFile + "", // srcDir + workingDir, // workingDir + destDir, // destDir + "", // depsDir + "", // repoHost, + "", // dnfConfigFile + "", // srcRepoHost + "testData/configfiles/srcconfig.yaml", // srcConfigFile + "", // srcRepoPathPrefix ) defer viper.Reset() if sources != nil { @@ -90,6 +92,6 @@ func TestCreateSrpmUnmodified(t *testing.T) { } testCreateSrpm(t, "debugedit-2", "debugedit", true, - []string{"debugedit-5.0-3.el9.src.rpm"}, + []string{"debugedit.src.rpm"}, sources) } diff --git a/cmd/testData/configfiles/srcconfig.yaml b/cmd/testData/configfiles/srcconfig.yaml new file mode 100644 index 0000000..3841924 --- /dev/null +++ b/cmd/testData/configfiles/srcconfig.yaml @@ -0,0 +1,7 @@ +--- +# yamllint disable rule:line-length +source-bundle: + el9: + url-format: "{{.Host}}/{{.PathPrefix}}/eext-testData/{{.Version}}/{{.PkgName}}.src.rpm" + version-labels: + default: el9/9-1/v20230810 diff --git a/cmd/testData/debugedit-2/eext.yaml b/cmd/testData/debugedit-2/eext.yaml index 5fee7fe..55f35b7 100644 --- a/cmd/testData/debugedit-2/eext.yaml +++ b/cmd/testData/debugedit-2/eext.yaml @@ -3,7 +3,10 @@ package: - name: debugedit upstream-sources: - - full-url: "{{.Host}}/artifactory/eext-sources/eext-testData/debugedit-5.0-3.el9.src.rpm" + - source-bundle: + name: el9 + override: + version: el9/9-1/v20230911 type: unmodified-srpm build: repo-bundle: