diff options
author | Paul Duncan <pabs@pablotron.org> | 2022-01-31 18:37:12 -0500 |
---|---|---|
committer | Paul Duncan <pabs@pablotron.org> | 2022-01-31 18:37:12 -0500 |
commit | 531c15b6c5f6c3d274ffec11a15b0ad22d685a90 (patch) | |
tree | f6bb3c61fc70819ae37e8a2390010fe5592754cb /main.go | |
parent | f77d9ce238dc4c86a605770b33f27d2cb0d51eb3 (diff) | |
download | cvez-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.go | 25 |
1 files changed, 4 insertions, 21 deletions
@@ -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() |