bugfix: use absolute path to when accessing file sytem (unittest discoverd :-)
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
This commit is contained in:
parent
abf318ae90
commit
96ca5b6988
1 changed files with 2 additions and 2 deletions
|
@ -114,7 +114,7 @@ class Object(object):
|
||||||
@property
|
@property
|
||||||
def parameters(self):
|
def parameters(self):
|
||||||
if not self.__parameters:
|
if not self.__parameters:
|
||||||
self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.path, "parameter"))
|
self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.absolute_path, "parameter"))
|
||||||
return self.__parameters
|
return self.__parameters
|
||||||
|
|
||||||
@parameters.setter
|
@parameters.setter
|
||||||
|
@ -122,7 +122,7 @@ class Object(object):
|
||||||
if isinstance(value, cdist.core.property.DirectoryDict):
|
if isinstance(value, cdist.core.property.DirectoryDict):
|
||||||
self.__parameters = value
|
self.__parameters = value
|
||||||
else:
|
else:
|
||||||
self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.path, "parameter"), value)
|
self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.absolute_path, "parameter"), value)
|
||||||
### /parameters
|
### /parameters
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue