Browse Source

Minor fixes

世界 3 years ago
parent
commit
968430c338
3 changed files with 5 additions and 3 deletions
  1. 1 0
      common/tls/std_server.go
  2. 1 0
      experimental/v2rayapi/stats.go
  3. 3 3
      test/mux_cool_test.go

+ 1 - 0
common/tls/std_server.go

@@ -45,6 +45,7 @@ func newSTDServer(ctx context.Context, logger log.Logger, options option.Inbound
 	var err error
 	if options.ACME != nil && len(options.ACME.Domain) > 0 {
 		tlsConfig, acmeService, err = startACME(ctx, common.PtrValueOrDefault(options.ACME))
+		//nolint:staticcheck
 		if err != nil {
 			return nil, err
 		}

+ 1 - 0
experimental/v2rayapi/stats.go

@@ -181,6 +181,7 @@ func (s *StatsService) GetSysStats(ctx context.Context, request *SysStatsRequest
 func (s *StatsService) mustEmbedUnimplementedStatsServiceServer() {
 }
 
+//nolint:staticcheck
 func (s *StatsService) loadOrCreateCounter(name string, counter *atomic.Int64) *atomic.Int64 {
 	counter, loaded := s.counters[name]
 	if !loaded {

+ 3 - 3
test/mux_cool_test.go

@@ -55,7 +55,7 @@ func TestMuxCoolServer(t *testing.T) {
 		},
 	})
 
-	testSuit(t, clientPort, testPort)
+	testSuitSimple(t, clientPort, testPort)
 }
 
 func TestMuxCoolClient(t *testing.T) {
@@ -105,7 +105,7 @@ func TestMuxCoolClient(t *testing.T) {
 			},
 		},
 	})
-	testSuit(t, clientPort, testPort)
+	testSuitSimple(t, clientPort, testPort)
 }
 
 func TestMuxCoolSelf(t *testing.T) {
@@ -166,5 +166,5 @@ func TestMuxCoolSelf(t *testing.T) {
 			},
 		},
 	})
-	testSuit(t, clientPort, testPort)
+	testSuitSimple(t, clientPort, testPort)
 }