diff --git a/.codecov.yml b/.codecov.yml index fde387c8d7a..58e1eb75695 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -11,6 +11,7 @@ ignore: - "thrift-gen/*/*" - "**/thrift-0.9.2/*" - "**/main.go" + - "examples/hotrod" coverage: precision: 2 diff --git a/examples/hotrod/cmd/.nocover b/examples/hotrod/cmd/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/cmd/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/cmd/empty_test.go b/examples/hotrod/cmd/empty_test.go new file mode 100644 index 00000000000..e81a798d0c3 --- /dev/null +++ b/examples/hotrod/cmd/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package cmd + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/pkg/delay/.nocover b/examples/hotrod/pkg/delay/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/pkg/delay/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/pkg/delay/empty_test.go b/examples/hotrod/pkg/delay/empty_test.go new file mode 100644 index 00000000000..75c6d1e8a8d --- /dev/null +++ b/examples/hotrod/pkg/delay/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package delay + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/pkg/httperr/.nocover b/examples/hotrod/pkg/httperr/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/pkg/httperr/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/pkg/httperr/empty_test.go b/examples/hotrod/pkg/httperr/empty_test.go new file mode 100644 index 00000000000..73a7986c991 --- /dev/null +++ b/examples/hotrod/pkg/httperr/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httperr + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/pkg/log/.nocover b/examples/hotrod/pkg/log/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/pkg/log/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/pkg/log/empty_test.go b/examples/hotrod/pkg/log/empty_test.go new file mode 100644 index 00000000000..313bc0b5a92 --- /dev/null +++ b/examples/hotrod/pkg/log/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package log + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/pkg/pool/.nocover b/examples/hotrod/pkg/pool/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/pkg/pool/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/pkg/pool/empty_test.go b/examples/hotrod/pkg/pool/empty_test.go new file mode 100644 index 00000000000..fc9263f8115 --- /dev/null +++ b/examples/hotrod/pkg/pool/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package pool + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/pkg/tracing/.nocover b/examples/hotrod/pkg/tracing/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/pkg/tracing/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/pkg/tracing/empty_test.go b/examples/hotrod/pkg/tracing/empty_test.go new file mode 100644 index 00000000000..8f76b53ef73 --- /dev/null +++ b/examples/hotrod/pkg/tracing/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package tracing + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/services/config/.nocover b/examples/hotrod/services/config/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/services/config/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/services/config/empty_test.go b/examples/hotrod/services/config/empty_test.go new file mode 100644 index 00000000000..7b868ab9b52 --- /dev/null +++ b/examples/hotrod/services/config/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package config + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/services/customer/.nocover b/examples/hotrod/services/customer/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/services/customer/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/services/customer/empty_test.go b/examples/hotrod/services/customer/empty_test.go new file mode 100644 index 00000000000..5df12a80314 --- /dev/null +++ b/examples/hotrod/services/customer/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package customer + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/services/driver/.nocover b/examples/hotrod/services/driver/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/services/driver/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/services/driver/empty_test.go b/examples/hotrod/services/driver/empty_test.go new file mode 100644 index 00000000000..cf898e03edb --- /dev/null +++ b/examples/hotrod/services/driver/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package driver + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/services/frontend/.nocover b/examples/hotrod/services/frontend/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/services/frontend/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/services/frontend/empty_test.go b/examples/hotrod/services/frontend/empty_test.go new file mode 100644 index 00000000000..30dd9391ab3 --- /dev/null +++ b/examples/hotrod/services/frontend/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package frontend + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +} diff --git a/examples/hotrod/services/route/.nocover b/examples/hotrod/services/route/.nocover deleted file mode 100644 index 1e107f52e47..00000000000 --- a/examples/hotrod/services/route/.nocover +++ /dev/null @@ -1 +0,0 @@ -examples diff --git a/examples/hotrod/services/route/empty_test.go b/examples/hotrod/services/route/empty_test.go new file mode 100644 index 00000000000..bc61c746ce9 --- /dev/null +++ b/examples/hotrod/services/route/empty_test.go @@ -0,0 +1,25 @@ +// Copyright (c) 2024 The Jaeger Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package route + +import ( + "testing" + + "go.uber.org/goleak" +) + +func TestMain(m *testing.M) { + goleak.VerifyTestMain(m) +}