Add tests for AxisToButton rule. (WIP)
This commit is contained in:
parent
47fac539da
commit
e93187b8a5
4 changed files with 76 additions and 14 deletions
|
@ -15,15 +15,6 @@ type RuleTargetAxisTests struct {
|
|||
call *mock.Call
|
||||
}
|
||||
|
||||
type InputDeviceMock struct {
|
||||
mock.Mock
|
||||
}
|
||||
|
||||
func (m *InputDeviceMock) AbsInfos() (map[evdev.EvCode]evdev.AbsInfo, error) {
|
||||
args := m.Called()
|
||||
return args.Get(0).(map[evdev.EvCode]evdev.AbsInfo), args.Error(1)
|
||||
}
|
||||
|
||||
func (t *RuleTargetAxisTests) SetupTest() {
|
||||
t.mock = new(InputDeviceMock)
|
||||
t.call = t.mock.On("AbsInfos").Return(map[evdev.EvCode]evdev.AbsInfo{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue