MCPcopy Create free account
hub / github.com/containerd/nerdctl / pushToIPFS

Function pushToIPFS

cmd/nerdctl/ipfs/ipfs_registry_linux_test.go:38–50  ·  view source on GitHub ↗
(helpers test.Helpers, name string, opts ...string)

Source from the content-addressed store, hash-verified

36)
37
38func pushToIPFS(helpers test.Helpers, name string, opts ...string) string {
39 var ipfsCID string
40 cmd := helpers.Command("push", "ipfs://"+name)
41 cmd.WithArgs(opts...)
42 cmd.Run(&test.Expected{
43 Output: func(stdout string, t tig.T) {
44 lines := strings.Split(stdout, "\n")
45 assert.Equal(t, len(lines) >= 2, true)
46 ipfsCID = lines[len(lines)-2]
47 },
48 })
49 return ipfsCID
50}
51
52func TestIPFSNerdctlRegistry(t *testing.T) {
53 testCase := nerdtest.Setup()

Callers 5

subtestTestIPFSCompNoBFunction · 0.85
TestIPFSCompBuildFunction · 0.85
TestIPFSSimpleFunction · 0.85
TestIPFSAddrWithKuboFunction · 0.85
TestIPFSNerdctlRegistryFunction · 0.85

Calls 3

CommandMethod · 0.65
WithArgsMethod · 0.65
RunMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…