aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2022-01-31 18:37:12 -0500
committerPaul Duncan <pabs@pablotron.org>2022-01-31 18:37:12 -0500
commit531c15b6c5f6c3d274ffec11a15b0ad22d685a90 (patch)
treef6bb3c61fc70819ae37e8a2390010fe5592754cb /main.go
parentf77d9ce238dc4c86a605770b33f27d2cb0d51eb3 (diff)
downloadcvez-531c15b6c5f6c3d274ffec11a15b0ad22d685a90.tar.bz2
cvez-531c15b6c5f6c3d274ffec11a15b0ad22d685a90.zip
move feed tests to internal/feed/feed_test.go, add internal/feed/testdata
Diffstat (limited to 'main.go')
-rw-r--r--main.go25
1 files changed, 4 insertions, 21 deletions
diff --git a/main.go b/main.go
index 84e16bb..e820184 100644
--- a/main.go
+++ b/main.go
@@ -1,31 +1,14 @@
package main
import (
- "encoding/json"
+ // "encoding/json"
// "fmt"
- "log"
+ // "log"
// "nvd/internal/cvss"
- "nvd/internal/feed"
- "os"
+ // "nvd/internal/feed"
+ // "os"
)
-// Test feed parser
-func testFeedParser() {
- var f feed.Feed
-
- // decode cve feed
- d := json.NewDecoder(os.Stdin)
- if err := d.Decode(&f); err != nil {
- log.Fatal(err)
- }
-
- // create json encoder
- e := json.NewEncoder(os.Stdout)
- if err := e.Encode(f); err != nil {
- log.Fatal(err)
- }
-}
-
func main() {
// testMetaParser()
// testFeedParser()