diff --git a/examples/ext/synth_shed/tests/test_synth_shed.py b/examples/ext/synth_shed/tests/test_synth_shed.py index d3be8f2..28bcb87 100644 --- a/examples/ext/synth_shed/tests/test_synth_shed.py +++ b/examples/ext/synth_shed/tests/test_synth_shed.py @@ -2,8 +2,40 @@ # -*- coding: utf-8 -*- # This file is under GNU Affero General Public License 3.0 # see LICENSE.txt - +import pytest +from synth_shed import * import synth_shed -def test_synth_shed(): - synth_shed +def test_synth_shed_init(): + init_synth_shed() + +# @pytest.mark.skip(reason="") +def test_Fds() : + brand = "Korg" + model = "MS20" + osc_count = 2 + s = synth_create(brand,model,osc_count) + print("brand:", s.brand) + print("model:", s.model) + print("osc_count", s.osc_count) + print("technolgy:",s.technolgy) + print("filter.tech:",s.filter.technology) + print("filter.type:",s.filter.type) + + assert s.brand == brand + assert s.model == model + assert s.osc_count == osc_count + assert s.technolgy == synth_shed._tech.ANALOG + assert s.filter.technology == synth_shed._tech.ANALOG + assert s.filter.type == synth_shed._filtertype.LPF + + print(play_synth(s)) + + +def test_tech_to_string(): + str = tech_to_string(synth_shed._tech.ANALOG) + print(str) + assert str == "ANALOG" + str = tech_to_string(synth_shed._tech.DIGITAL) + print(str) + assert str == "DIGITAL"