Return-Path: X-Original-To: apmail-deltacloud-dev-archive@www.apache.org Delivered-To: apmail-deltacloud-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 77228DE30 for ; Wed, 13 Feb 2013 13:42:13 +0000 (UTC) Received: (qmail 8169 invoked by uid 500); 13 Feb 2013 13:42:13 -0000 Delivered-To: apmail-deltacloud-dev-archive@deltacloud.apache.org Received: (qmail 8125 invoked by uid 500); 13 Feb 2013 13:42:13 -0000 Mailing-List: contact dev-help@deltacloud.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@deltacloud.apache.org Delivered-To: mailing list dev@deltacloud.apache.org Received: (qmail 8110 invoked by uid 99); 13 Feb 2013 13:42:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Feb 2013 13:42:12 +0000 Date: Wed, 13 Feb 2013 13:42:12 +0000 (UTC) From: "Ronelle Landy (JIRA)" To: dev@deltacloud.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Assigned] (DTACLOUD-471) Need to cleanly skip CIMI Resource Metadata tests for unsupported capabilities MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DTACLOUD-471?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ronelle Landy reassigned DTACLOUD-471: -------------------------------------- Assignee: Ronelle Landy (was: Marios Andreou) > Need to cleanly skip CIMI Resource Metadata tests for unsupported capabilities > ------------------------------------------------------------------------------ > > Key: DTACLOUD-471 > URL: https://issues.apache.org/jira/browse/DTACLOUD-471 > Project: DeltaCloud > Issue Type: Bug > Components: CIMI/Frontend > Reporter: Marios Andreou > Assignee: Ronelle Landy > > Context from rlandy via e-mail: > If we run the resource metadata tests against any provider other than mock, rmd3_test.rb and rmd4_test.rb will error out in the lines that determine the index of the capability under test. > Question is: do we need to write some protective code to avoid failures like: > unless rmd_coll.json["resourceMetadata"][machine_index]["capabilities"].nil?() > unless rmd_coll.json["resourceMetadata"][machine_index]["capabilities"] > run test .... > or is it ok to assume that these tests can and will only be executed where the capabilities exist? > If we do need the protective code, the failures occur on line 38 in rmd3_test.rb and line 40 in rmd4_test.rb - where we check for the index of the capability. Since this code shows up before any it ... do ... end testpoints, using 'skip' is not suitable. Is it ok to just add the unless lines above to the tests or is there a better (more ruby-stlyish) way to skip the entire test? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira