From 766885816a2d6510073e50cf60dc9bdf57b4abd1 Mon Sep 17 00:00:00 2001 From: Michael Wan Date: Tue, 21 Aug 2018 00:11:13 -0400 Subject: [PATCH] bugfix: return sorted env slice in mergeEnvSlice Signed-off-by: Michael Wan --- daemon/mgr/container_utils_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/daemon/mgr/container_utils_test.go b/daemon/mgr/container_utils_test.go index 0e1e803d5..78ca305b0 100644 --- a/daemon/mgr/container_utils_test.go +++ b/daemon/mgr/container_utils_test.go @@ -8,6 +8,7 @@ import ( "github.com/alibaba/pouch/apis/types" "github.com/alibaba/pouch/pkg/collect" "github.com/alibaba/pouch/pkg/meta" + "github.com/alibaba/pouch/pkg/utils" "github.com/stretchr/testify/assert" ) @@ -262,7 +263,7 @@ func Test_mergeEnvSlice(t *testing.T) { t.Errorf("mergeEnvSlice() error = %v, wantErr %v", err, tt.wantErr) return } - if !reflect.DeepEqual(got, tt.want) { + if !utils.StringSliceEqual(got, tt.want) { t.Errorf("mergeEnvSlice() = %v, want %v", got, tt.want) } })