From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 2DE7ADE3 for ; Mon, 12 Jun 2017 08:08:29 +0200 (CEST) Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga105.fm.intel.com with ESMTP; 11 Jun 2017 23:08:29 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,332,1493708400"; d="scan'208";a="113176410" Received: from dpdk-test38.sh.intel.com ([10.239.129.178]) by fmsmga005.fm.intel.com with ESMTP; 11 Jun 2017 23:08:28 -0700 From: Marvin Liu To: dts@dpdk.org Cc: Marvin Liu Date: Mon, 12 Jun 2017 02:06:32 -0400 Message-Id: <1497247592-24657-1-git-send-email-yong.liu@intel.com> X-Mailer: git-send-email 1.9.3 Subject: [dts] [PATCH V1] framework dut: do not exit when no network connection found X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Jun 2017 06:08:30 -0000 Some suites like unit suites still can work without network connection. So output warning message rather than raise exception when no network connection found. Signed-off-by: Marvin Liu diff --git a/framework/dut.py b/framework/dut.py index 3e90670..ddbe64e 100644 --- a/framework/dut.py +++ b/framework/dut.py @@ -206,7 +206,7 @@ class Dut(Crb): for port_info in self.ports_info: self.logger.info(port_info) if self.ports_map is None or len(self.ports_map) == 0: - raise ValueError("ports_map should not be empty, please check all links") + self.logger.warning("ports_map should not be empty, please check all links") # initialize virtualization resource pool self.virt_pool = VirtResource(self) -- 1.9.3