Small bugfixes in the wake of the cmdset changes. Resolves issue 148.
This commit is contained in:
parent
9d80284504
commit
75956de7d1
3 changed files with 8 additions and 3 deletions
|
|
@ -288,10 +288,10 @@ class CmdSetHandler(object):
|
||||||
if cmdset:
|
if cmdset:
|
||||||
if self.cmdset_stack:
|
if self.cmdset_stack:
|
||||||
self.cmdset_stack[0] = cmdset
|
self.cmdset_stack[0] = cmdset
|
||||||
self.mergetype_stack.insert[0] = cmdset.mergetype
|
self.mergetype_stack[0] = cmdset.mergetype
|
||||||
else:
|
else:
|
||||||
self.cmdset_stack = [cmdset]
|
self.cmdset_stack = [cmdset]
|
||||||
self.mergetype_stack = cmdset.mergetype
|
self.mergetype_stack = [cmdset.mergetype]
|
||||||
|
|
||||||
if permanent:
|
if permanent:
|
||||||
if self.permanent_paths:
|
if self.permanent_paths:
|
||||||
|
|
|
||||||
|
|
@ -223,6 +223,7 @@ class TestPy(CommandTest):
|
||||||
self.execute_cmd("@py 1+2", [">>> 1+2", "<<< 3"])
|
self.execute_cmd("@py 1+2", [">>> 1+2", "<<< 3"])
|
||||||
class TestScripts(CommandTest):
|
class TestScripts(CommandTest):
|
||||||
def test_call(self):
|
def test_call(self):
|
||||||
|
script = create.create_script(None, "test")
|
||||||
self.execute_cmd("@scripts", "id")
|
self.execute_cmd("@scripts", "id")
|
||||||
class TestObjects(CommandTest):
|
class TestObjects(CommandTest):
|
||||||
def test_call(self):
|
def test_call(self):
|
||||||
|
|
@ -272,4 +273,8 @@ class TestWall(CommandTest):
|
||||||
|
|
||||||
# building.py command tests
|
# building.py command tests
|
||||||
|
|
||||||
|
class TestScript(CommandTest):
|
||||||
|
def test_call(self):
|
||||||
|
self.execute_cmd("@script TestChar = examples.bodyfunctions.BodyFunctions", "Script successfully added")
|
||||||
|
|
||||||
#TODO
|
#TODO
|
||||||
|
|
|
||||||
|
|
@ -612,7 +612,7 @@ class TypedObject(SharedMemoryModel):
|
||||||
errstring += "\nThis seems to be just the path to a module. You need"
|
errstring += "\nThis seems to be just the path to a module. You need"
|
||||||
errstring += " to specify the actual typeclass name inside the module too."
|
errstring += " to specify the actual typeclass name inside the module too."
|
||||||
errstring += "\n Typeclass '%s' failed to load." % path
|
errstring += "\n Typeclass '%s' failed to load." % path
|
||||||
defpath = object.__getattribute__(self, default_typeclass_path)
|
defpath = object.__getattribute__(self, "default_typeclass_path")
|
||||||
errstring += " Using Default class '%s'." % defpath
|
errstring += " Using Default class '%s'." % defpath
|
||||||
self.db_typeclass_path = defpath
|
self.db_typeclass_path = defpath
|
||||||
self.save()
|
self.save()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue