Skip to content

Commit

Permalink
Remove unused funcs (#1916)
Browse files Browse the repository at this point in the history
  • Loading branch information
sebrandon1 authored Mar 13, 2024
1 parent aa59d28 commit 3db860e
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 253 deletions.
2 changes: 0 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ go 1.22.1

require (
github.com/Masterminds/semver/v3 v3.2.1
github.com/basgys/goxml2json v1.1.0
github.com/sirupsen/logrus v1.9.3
github.com/spf13/cobra v1.8.0
github.com/stretchr/testify v1.9.0
Expand Down Expand Up @@ -41,7 +40,6 @@ require (
github.com/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230321174746-8dcc6526cfb1 // indirect
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/bitly/go-simplejson v0.5.0 // indirect
github.com/blang/semver v3.5.1+incompatible // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/cenkalti/backoff/v4 v4.2.1 // indirect
Expand Down
4 changes: 0 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,10 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPd
github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs=
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so=
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw=
github.com/basgys/goxml2json v1.1.0 h1:4ln5i4rseYfXNd86lGEB+Vi652IsIXIvggKM/BhUKVw=
github.com/basgys/goxml2json v1.1.0/go.mod h1:wH7a5Np/Q4QoECFIU8zTQlZwZkrilY0itPfecMw41Dw=
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
github.com/bitly/go-simplejson v0.5.0 h1:6IH+V8/tVMab511d5bn4M7EwGXZf9Hj6i2xSwkNEM+Y=
github.com/bitly/go-simplejson v0.5.0/go.mod h1:cXHtHw4XUPsvGaxgjIAn8PhEWG9NfngEKAMDJEczWVA=
github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ=
github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM=
Expand Down
26 changes: 0 additions & 26 deletions pkg/claimhelper/claimhelper.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import (
j "encoding/json"
"encoding/xml"
"fmt"
"path/filepath"
"sort"
"strconv"
"strings"
Expand All @@ -32,7 +31,6 @@ import (

"github.com/test-network-function/cnf-certification-test/pkg/checksdb"
"github.com/test-network-function/cnf-certification-test/pkg/diagnostics"
"github.com/test-network-function/cnf-certification-test/pkg/junit"
"github.com/test-network-function/cnf-certification-test/pkg/provider"
"github.com/test-network-function/cnf-certification-test/pkg/versions"
"github.com/test-network-function/test-network-function-claim/pkg/claim"
Expand Down Expand Up @@ -388,27 +386,3 @@ func CreateClaimRoot() *claim.Root {
},
}
}

// LoadJUnitXMLIntoMap converts junitFilename's XML-formatted JUnit test results into a Go map, and adds the result to
// the result Map.
func LoadJUnitXMLIntoMap(result map[string]interface{}, junitFilename, key string) {
var err error
if key == "" {
var extension = filepath.Ext(junitFilename)
key = junitFilename[0 : len(junitFilename)-len(extension)]
}
result[key], err = junit.ExportJUnitAsMap(junitFilename)
if err != nil {
log.Error("error reading JUnit XML file into JSON: %v", err)
os.Exit(1)
}
}

// AppendCNFFeatureValidationReportResults is a helper method to add the results of running the cnf-features-deploy
// test suite to the claim file.
func AppendCNFFeatureValidationReportResults(junitPath *string, junitMap map[string]interface{}) {
cnfFeaturesDeployJUnitFile := filepath.Join(*junitPath, CNFFeatureValidationJunitXMLFileName)
if _, err := os.Stat(cnfFeaturesDeployJUnitFile); err == nil {
LoadJUnitXMLIntoMap(junitMap, cnfFeaturesDeployJUnitFile, CNFFeatureValidationReportKey)
}
}
177 changes: 0 additions & 177 deletions pkg/junit/convert.go

This file was deleted.

44 changes: 0 additions & 44 deletions pkg/junit/convert_test.go

This file was deleted.

0 comments on commit 3db860e

Please sign in to comment.