2023-07-17 14:14:16 +01:00
|
|
|
require "minitest/autorun"
|
2023-08-07 22:32:35 +01:00
|
|
|
require "voicemeeter"
|
2023-07-17 14:14:16 +01:00
|
|
|
|
|
|
|
class Test
|
2023-07-18 07:35:33 +01:00
|
|
|
class << self
|
|
|
|
attr_reader :vm, :data
|
2023-07-17 14:14:16 +01:00
|
|
|
end
|
|
|
|
|
2023-07-18 07:35:33 +01:00
|
|
|
@vm = Voicemeeter::Remote.new([:basic, :banana, :potato].sample)
|
|
|
|
vm.login
|
|
|
|
puts "Running #{vm.kind.name} tests"
|
|
|
|
|
2023-07-17 20:00:25 +01:00
|
|
|
TestMap = Data.define(:name, :phys_in, :virt_in, :phys_out, :virt_out, :button_lower, :button_higher, :vban_in, :vban_out)
|
2023-07-17 14:14:16 +01:00
|
|
|
|
2023-07-17 20:00:25 +01:00
|
|
|
@data = TestMap.new(
|
2023-07-18 07:35:33 +01:00
|
|
|
vm.kind.name,
|
|
|
|
vm.kind.phys_in - 1,
|
|
|
|
vm.kind.virt_in - 1,
|
|
|
|
vm.kind.phys_out - 1,
|
|
|
|
vm.kind.virt_out - 1,
|
2023-07-17 20:00:25 +01:00
|
|
|
0, 79,
|
2023-07-18 07:35:33 +01:00
|
|
|
vm.kind.vban[0] - 1,
|
|
|
|
vm.kind.vban[1] - 1
|
2023-07-17 20:00:25 +01:00
|
|
|
)
|
2023-07-17 14:14:16 +01:00
|
|
|
|
2023-07-18 07:35:33 +01:00
|
|
|
Minitest.after_run { vm.logout }
|
2023-07-17 14:14:16 +01:00
|
|
|
end
|