'fpinball': FpinballGenerator(), 'lightspark': LightsparkGenerator(), 'ruffle': RuffleGenerator(), 'duckstation': DuckstationGenerator(), 'drastic': DrasticGenerator(), 'xemu': XemuGenerator(), 'cgenius': CGeniusGenerator(), 'flatpak': FlatpakGenerator(), 'steam': SteamGenerator(), 'ecwolf': ECWolfGenerator(), 'lexaloffle': LexaloffleGenerator(), 'model2emu': Model2EmuGenerator(), 'sonic2013': SonicRetroGenerator(), 'soniccd': SonicRetroGenerator(), 'gsplus': GSplusGenerator(), 'fba2x': Fba2xGenerator(), 'yuzu': YuzuGenerator(), 'samcoupe': SamcoupeGenerator(), 'abuse': AbuseGenerator(), 'cdogs': CdogsGenerator(), 'hcl': HclGenerator(), #'play': PlayGenerator(), } def squashfs_begin(rom): eslog.debug("squashfs_begin({})".format(rom)) rommountpoint = "/var/run/squashfs/" + os.path.basename(rom)[:-9] if not os.path.exists("/var/run/squashfs"): os.mkdir("/var/run/squashfs")
from generators.vice.viceGenerator import ViceGenerator from generators.fsuae.fsuaeGenerator import FsuaeGenerator from generators.amiberry.amiberryGenerator import AmiberryGenerator from generators.citra.citraGenerator import CitraGenerator import controllersConfig as controllers import signal import batoceraFiles import os import subprocess import json import utils.videoMode as videoMode from utils.logger import eslog generators = { 'fba2x': Fba2xGenerator(), 'kodi': KodiGenerator(), 'linapple': LinappleGenerator(os.path.join(batoceraFiles.HOME_INIT, '.linapple'), os.path.join(batoceraFiles.HOME, '.linapple')), 'libretro': LibretroGenerator(), 'moonlight': MoonlightGenerator(), 'scummvm': ScummVMGenerator(), 'dosbox': DosBoxGenerator(), 'mupen64plus': MupenGenerator(),
shaders='', ratio='auto', smooth='2', emulator='pifba', configfile='lol') # test inputs basicInputs1 = { 'hotkey': controllersConfig.Input("hotkey", "button", "10", "1") } basicController1 = controllersConfig.Controller("contr1", "joypad", "GUID1", "0", "Joypad1RealName", basicInputs1) rom = "MyRom.zip" fba2xGen = Fba2xGenerator() fba2xGenerator.fba2xConfig.fbaSettings = fba2xConfig.fbaSettings class TestLibretroGenerator(unittest.TestCase): def test_generate_system_no_custom_settings(self): command = fba2xGen.generate(fbaSystem, rom, dict()) self.assertEquals(command.videomode, '4') self.assertEquals(command.array, [ '/usr/bin/fba2x', '--configfile', FBA2X_CUSTOM_CFG_FILE, 'MyRom.zip' ]) def test_generate_system_custom_settings(self): command = fba2xGen.generate(fbaSystemCustom, rom, dict()) self.assertEquals(command.videomode, '6')