testlipo

package
v0.8.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var TestDir = filepath.Join(os.TempDir(), "testlipo-output")

Functions

func DiffPerm added in v0.5.0

func DiffPerm(t *testing.T, wantBin, gotBin string)

func DiffSha256

func DiffSha256(t *testing.T, wantBin, gotBin string)

func PatchFat64Reserved added in v0.5.0

func PatchFat64Reserved(t *testing.T, p string)

Types

type BinManager added in v0.8.3

type BinManager struct {
	Dir string
	// contains filtered or unexported fields
}

func NewBinManager added in v0.8.3

func NewBinManager(dir string) *BinManager

type LipoBin

type LipoBin struct {
	Bin string
	// contains filtered or unexported fields
}

func NewLipoBin

func NewLipoBin(t *testing.T, opts ...Opt) LipoBin

func (*LipoBin) Archs

func (l *LipoBin) Archs(t *testing.T, in string) string

func (*LipoBin) Create

func (l *LipoBin) Create(t *testing.T, out string, inputs ...string)

func (*LipoBin) DetailedInfo

func (l *LipoBin) DetailedInfo(t *testing.T, bins ...string) string

func (*LipoBin) Extract

func (l *LipoBin) Extract(t *testing.T, out, in string, arches []string)

func (*LipoBin) ExtractFamily

func (l *LipoBin) ExtractFamily(t *testing.T, out, in string, arches []string)

func (*LipoBin) Info added in v0.1.1

func (l *LipoBin) Info(t *testing.T, bins ...string) string

func (*LipoBin) Remove

func (l *LipoBin) Remove(t *testing.T, out, in string, arches []string)

func (*LipoBin) Replace

func (l *LipoBin) Replace(t *testing.T, out, in string, archBins [][2]string)

func (*LipoBin) Thin

func (l *LipoBin) Thin(t *testing.T, out, in, arch string)

type Opt added in v0.2.0

type Opt func(l *LipoBin)

func IgnoreErr added in v0.6.0

func IgnoreErr(v bool) Opt

IgnoreErr will ignore a lipo command error not to call t.Fatal()

func WithFat64 added in v0.2.0

func WithFat64(v bool) Opt

func WithHideArm64 added in v0.2.0

func WithHideArm64(v bool) Opt

func WithSegAlign added in v0.2.0

func WithSegAlign(sa []string) Opt

type TestLipo

type TestLipo struct {
	*BinManager

	FatBin string
	LipoBin
	// contains filtered or unexported fields
}

func Setup

func Setup(t *testing.T, bm *BinManager, arches []string, opts ...Opt) *TestLipo

func (*TestLipo) Bin

func (l *TestLipo) Bin(t *testing.T, arch string) (path string)

func (*TestLipo) Bins

func (l *TestLipo) Bins(t *testing.T) (paths []string)

func (*TestLipo) NewArchBin

func (l *TestLipo) NewArchBin(t *testing.T, arch string) (path string)

func (*TestLipo) NewArchObj added in v0.2.0

func (l *TestLipo) NewArchObj(t *testing.T, arch string) (path string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL