factory_test.go 450 B

123456789101112131415161718
  1. // Copyright The OpenTelemetry Authors
  2. // SPDX-License-Identifier: Apache-2.0
  3. package cassandraexporter
  4. import (
  5. "testing"
  6. "github.com/stretchr/testify/assert"
  7. "go.opentelemetry.io/collector/component/componenttest"
  8. )
  9. func TestCreateDefaultConfig(t *testing.T) {
  10. factory := NewFactory()
  11. cfg := factory.CreateDefaultConfig()
  12. assert.NotNil(t, cfg, "failed to create default config")
  13. assert.NoError(t, componenttest.CheckConfigStruct(cfg))
  14. }