From 450a6898f5062d461d5c0932182e3140c6f16d9e Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Mon, 17 Jul 2017 14:44:53 +0200 Subject: Remove double defined constants --- zsig/header.go | 5 ----- zsig/header_test.go | 4 ++-- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/zsig/header.go b/zsig/header.go index aa1c13b..7bf87ed 100644 --- a/zsig/header.go +++ b/zsig/header.go @@ -18,11 +18,6 @@ type ZHeader struct { Sums [][]byte } -const ( - DefaultAlg = "SHA512/256" - DefaultBlockSize = 65536 -) - func (h ZHeader) Print(w io.Writer) error { fmt.Fprintf(w, "date=%v\n", h.Date.Format(time.RFC3339)) fmt.Fprintf(w, "key=%v\n", h.KeyFile) diff --git a/zsig/header_test.go b/zsig/header_test.go index ca10b27..55921dd 100644 --- a/zsig/header_test.go +++ b/zsig/header_test.go @@ -14,8 +14,8 @@ func TestZHeader(t *testing.T) { h := ZHeader{ Date: date, KeyFile: "some.key", - Alg: DefaultAlg, - BlockSize: DefaultBlockSize, + Alg: Alg, + BlockSize: BlockSize, Sums: [][]byte{ []byte{0, 1, 2, 3, 4, 5}, []byte{6, 7, 8, 9, 10}, -- cgit v1.2.3