Example #1
0
def libmgr_cfg_mgr_lib_default_test():
  lcd = LibCfg(LibCfg.CREATE_MODE_OFF, 1, LibCfg.EXPUNGE_MODE_NO_MEM)
  lmc = LibMgrCfg(lib_default=lcd)
  assert lmc.get_lib_cfg("bla.library") == lcd
  lc = LibCfg(LibCfg.CREATE_MODE_OFF, 1, LibCfg.EXPUNGE_MODE_NO_MEM)
  lmc.add_lib_cfg("bla.library", lc)
  assert lmc.get_lib_cfg("bla.library") == lc
Example #2
0
def libmgr_cfg_mgr_lib_test():
    lmc = LibMgrCfg()
    lc = LibCfg(LibCfg.CREATE_MODE_OFF, 1, LibCfg.EXPUNGE_MODE_NO_MEM)
    lmc.add_lib_cfg("bla.library", lc)
    assert lmc.get_lib_cfg("bla.library") == lc
    assert lmc.get_lib_cfg("foo.library") == LibCfg()
    lc2 = LibCfg(LibCfg.CREATE_MODE_AMIGA, 11, LibCfg.EXPUNGE_MODE_NO_MEM)
    lmc.add_lib_cfg("foo.library", lc2)
    assert lmc.get_lib_cfg("foo.library") == lc2