Esempio n. 1
0
func TestSystemReturnsCorrectArch(t *testing.T) {
	system := System{&Dpkg{"test_data"}}

	arch, err := system.Arch()
	assert.Nil(t, err)
	assert.Equal(t, pkg.Arch("beautiful"), arch)
}
Esempio n. 2
0
File: system.go Progetto: vosst/csi
// Arch queries the system architecture that the system has been built for.
//
// Returns an error if querying the information from the system fails.
func (self System) Arch() (pkg.Arch, error) {
	arch, err := self.dpkg.Architecture()
	return pkg.Arch(arch), err
}