From 2ca2b9f6f36b8a1698ce162abac53a5cb3c2856e Mon Sep 17 00:00:00 2001 From: Gary Wu Date: Thu, 14 Sep 2017 13:51:00 -0700 Subject: Add return checks and logging for docker functions Change-Id: I7cf2bf9397006034b155557bf4d4b155a5626a7a Issue-ID: INT-200 Signed-off-by: Gary Wu --- test/csit/tests/integration/vCPE/test1.robot | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'test/csit') diff --git a/test/csit/tests/integration/vCPE/test1.robot b/test/csit/tests/integration/vCPE/test1.robot index d9a9baf95..01a14e62f 100644 --- a/test/csit/tests/integration/vCPE/test1.robot +++ b/test/csit/tests/integration/vCPE/test1.robot @@ -17,15 +17,24 @@ SO ServiceInstance health check Run Docker [Arguments] ${image} ${name} ${parameters}=${EMPTY} ${result}= Run Process docker run --name ${name} ${parameters} -d ${image} shell=True - Log all output: ${result.stdout} + Should Be Equal As Integers ${result.rc} 0 + Log ${result.stdout} ${result}= Run Process docker inspect --format '{{ .NetworkSettings.IPAddress }}' ${name} shell=True + Should Be Equal As Integers ${result.rc} 0 + Log ${result.stdout} [Return] ${result.stdout} Kill Docker [Arguments] ${name} ${result}= Run Process docker logs ${name} shell=True + Should Be Equal As Integers ${result.rc} 0 + Log ${result.stdout} ${result}= Run Process docker kill ${name} shell=True + Should Be Equal As Integers ${result.rc} 0 + Log ${result.stdout} ${result}= Run Process docker rm ${name} shell=True + Should Be Equal As Integers ${result.rc} 0 + Log ${result.stdout} CheckUrl [Arguments] ${url} -- cgit 1.2.3-korg