MCPcopy Create free account
hub / github.com/cloudquery/cloudquery / TestPlugin

Function TestPlugin

plugins/destination/s3/client/client_test.go:27–54  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

25)
26
27func TestPlugin(t *testing.T) {
28 zero := int64(0)
29 for _, ft := range []filetypes.FormatType{
30 filetypes.FormatTypeCSV,
31 filetypes.FormatTypeJSON,
32 filetypes.FormatTypeParquet,
33 } {
34 s := spec.Spec{
35 Bucket: bucket,
36 Region: region,
37 Path: t.TempDir()[1:],
38 NoRotate: true,
39 BatchSizeBytes: &zero,
40 BatchSize: &zero,
41 FileSpec: filetypes.FileSpec{Format: ft},
42 }
43
44 t.Run("generic/"+string(ft), func(t *testing.T) {
45 t.Parallel()
46 testPlugin(t, &s)
47 })
48
49 t.Run("write/"+string(ft), func(t *testing.T) {
50 t.Parallel()
51 testPluginCustom(t, &s)
52 })
53 }
54}
55
56func testPlugin(t *testing.T, s *spec.Spec) {
57 ctx := context.Background()

Callers

nothing calls this directly

Calls 3

RunMethod · 0.80
testPluginFunction · 0.70
testPluginCustomFunction · 0.70

Tested by

no test coverage detected