projects
/
osm
/
SO.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge changes I4fd0f119,Ie3aa6347 into v2.0
[osm/SO.git]
/
rwlaunchpad
/
plugins
/
rwpkgmgr
/
test
/
utest_filesystem_proxy_dts.py
diff --git
a/rwlaunchpad/plugins/rwpkgmgr/test/utest_filesystem_proxy_dts.py
b/rwlaunchpad/plugins/rwpkgmgr/test/utest_filesystem_proxy_dts.py
index
75b310a
..
6bc5bd4
100755
(executable)
--- a/
rwlaunchpad/plugins/rwpkgmgr/test/utest_filesystem_proxy_dts.py
+++ b/
rwlaunchpad/plugins/rwpkgmgr/test/utest_filesystem_proxy_dts.py
@@
-66,11
+66,11
@@
class TestCase(rift.test.dts.AbstractDTSTest):
"launchpad/packages/vnfd",
uid)
"launchpad/packages/vnfd",
uid)
-
package_path = os.path.join(path, "pong_vnfd
")
+
asset_path = os.path.join(path, "icons
")
- os.makedirs(
package
_path)
+ os.makedirs(
asset
_path)
open(os.path.join(path, "pong_vnfd.xml"), "wb").close()
open(os.path.join(path, "pong_vnfd.xml"), "wb").close()
- open(os.path.join(path, "logo.png"), "wb").close()
+ open(os.path.join(
asset_
path, "logo.png"), "wb").close()
return uid, path
return uid, path
@@
-182,7
+182,8
@@
class TestCase(rift.test.dts.AbstractDTSTest):
"package_type": "VNFD",
"package_id": uid,
"external_url": "https://raw.githubusercontent.com/RIFTIO/RIFT.ware/master/rift-shell",
"package_type": "VNFD",
"package_id": uid,
"external_url": "https://raw.githubusercontent.com/RIFTIO/RIFT.ware/master/rift-shell",
- "package_path": "icons/rift-shell"})
+ "vnfd_file_type": "ICONS",
+ "package_path": "rift-shell"})
rpc_out = yield from self.dts.query_rpc(
"I,/rw-pkg-mgmt:package-file-add",
rpc_out = yield from self.dts.query_rpc(
"I,/rw-pkg-mgmt:package-file-add",
@@
-190,7
+191,7
@@
class TestCase(rift.test.dts.AbstractDTSTest):
ip)
yield from asyncio.sleep(5, loop=self.loop)
ip)
yield from asyncio.sleep(5, loop=self.loop)
- filepath = os.path.join(path, ip.package_path)
+ filepath = os.path.join(path, ip.
vnfd_file_type.lower(), ip.
package_path)
assert os.path.isfile(filepath)
mode = oct(os.stat(filepath)[stat.ST_MODE])
assert str(mode) == "0o100664"
assert os.path.isfile(filepath)
mode = oct(os.stat(filepath)[stat.ST_MODE])
assert str(mode) == "0o100664"
@@
-218,9
+219,10
@@
class TestCase(rift.test.dts.AbstractDTSTest):
ip = RwPkgMgmtYang.YangInput_RwPkgMgmt_PackageFileDelete.from_dict({
"package_type": "VNFD",
"package_id": uid,
ip = RwPkgMgmtYang.YangInput_RwPkgMgmt_PackageFileDelete.from_dict({
"package_type": "VNFD",
"package_id": uid,
+ "vnfd_file_type": "ICONS",
"package_path": "logo.png"})
"package_path": "logo.png"})
- assert os.path.isfile(os.path.join(path, ip.package_path))
+ assert os.path.isfile(os.path.join(path, ip.
vnfd_file_type.lower(), ip.
package_path))
rpc_out = yield from self.dts.query_rpc(
"I,/rw-pkg-mgmt:package-file-delete",
rpc_out = yield from self.dts.query_rpc(
"I,/rw-pkg-mgmt:package-file-delete",
@@
-228,7
+230,7
@@
class TestCase(rift.test.dts.AbstractDTSTest):
ip)
yield from asyncio.sleep(5, loop=self.loop)
ip)
yield from asyncio.sleep(5, loop=self.loop)
- assert not os.path.isfile(os.path.join(path, ip.package_path))
+ assert not os.path.isfile(os.path.join(path, ip.
vnfd_file_type.lower(), ip.
package_path))
shutil.rmtree(path)
shutil.rmtree(path)