MCPcopy Create free account
hub / github.com/AdRoll/baker / Run

Method Run

upload/s3_integration_test.go:36–50  ·  view source on GitHub ↗
(in <-chan baker.OutputRecord, upch chan<- string)

Source from the content-addressed store, hash-verified

34func (o *customOutput) CanShard() bool { return false }
35
36func (o *customOutput) Run(in <-chan baker.OutputRecord, upch chan<- string) error {
37 // Simulate a new file for each received record
38 nfiles := 0
39 for range in {
40 fpath := path.Join(o.path, nthFile(nfiles))
41 if err := os.WriteFile(fpath, nil, 0664); err != nil {
42 return err
43 }
44 nfiles++
45 upch <- fpath
46 time.Sleep(o.sleep)
47 }
48
49 return nil
50}
51
52func testIntegrationS3(callStop bool) func(t *testing.T) {
53 return func(t *testing.T) {

Callers

nothing calls this directly

Calls 1

nthFileFunction · 0.85

Tested by

no test coverage detected