From patchwork Thu Jul 12 13:40:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Sitnicki X-Patchwork-Id: 943057 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41RHL26yylz9s1R for ; Thu, 12 Jul 2018 23:47:06 +1000 (AEST) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 3B5CED7D; Thu, 12 Jul 2018 13:40:44 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 61097D59 for ; Thu, 12 Jul 2018 13:40:41 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.7.6 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id D22194FA for ; Thu, 12 Jul 2018 13:40:40 +0000 (UTC) Received: by mail-wr1-f41.google.com with SMTP id q10-v6so21759672wrd.4 for ; Thu, 12 Jul 2018 06:40:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=MsksL+AwbxDwEWR/P7+27KiEvSLkPSS4RbSh0oQXE1c=; b=Wgkk5mfVm/0MsGqlm1ujzGsWUuzNmWDDy+7PIG+jmBnYJuT3I/stus+qaDSP1B73f1 XE+ncO2/EKanu8KTZttOVioW8gDUQUIKCKoW/sht1SZk0nKCqFGQxo/NT7QjFlRiiY6/ 4U0+198SY9u7eZKbXwIFfEMFTmuTHLpZ+l8TT2SJX/ecuHWkbZUajgu6Ibnn85cXFUwM qXtPkJGXSGEhfHrmg6THll202HL5zRaDnli+kib0MQDeMgMg7LOZTM8Ic6XTMu3/1T3D QQdLGa070ssTGzRVvzdHVI8aGJjnbyGiyqVGQwGhr9DHzCX9AbGDyrWjRUhNjvB2AT6K 6Y2Q== X-Gm-Message-State: AOUpUlEWo2A6UzEcVG61KkryKHLZXZfoXZVhZj7El4SkghoJfg3Yqa8t gYAYSMmi3GikLISA0EVt9KQgqTQfA1M= X-Google-Smtp-Source: AAOMgpeYH4cVfvbOuLTXWSqNwB1Kq46N1CTFcdTkW0N8mZEpItrvsYVGH12lowPvfuG3KUEOc4hRXA== X-Received: by 2002:adf:9246:: with SMTP id 64-v6mr1887439wrj.109.1531402839350; Thu, 12 Jul 2018 06:40:39 -0700 (PDT) Received: from redhat.com (red-hat-inc.vlan404.asr1.mad1.gblx.net. [64.215.113.190]) by smtp.gmail.com with ESMTPSA id h12-v6sm2327972wmb.3.2018.07.12.06.40.38 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 12 Jul 2018 06:40:38 -0700 (PDT) From: Jakub Sitnicki To: dev@openvswitch.org Date: Thu, 12 Jul 2018 15:40:14 +0200 Message-Id: <20180712134016.14336-14-jkbs@redhat.com> X-Mailer: git-send-email 2.14.4 In-Reply-To: <20180712134016.14336-1-jkbs@redhat.com> References: <20180712134016.14336-1-jkbs@redhat.com> X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Subject: [ovs-dev] [PATCH v2 13/15] tests: Add test for ovn-nbctl dry run mode. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org Signed-off-by: Jakub Sitnicki --- tests/ovn-nbctl.at | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/tests/ovn-nbctl.at b/tests/ovn-nbctl.at index 73a61a4be..89daf631a 100644 --- a/tests/ovn-nbctl.at +++ b/tests/ovn-nbctl.at @@ -1382,3 +1382,24 @@ inactivity_probe : 30000 OVN_NBCTL_TEST_STOP AT_CLEANUP + +dnl --------------------------------------------------------------------- + +AT_SETUP([ovn-nbctl - dry run mode]) +OVN_NBCTL_TEST_START + +# Check that dry run has no permanent effect. +AT_CHECK([ovn-nbctl --dry-run ls-add ls0 -- ls-list | uuidfilt], [0], [dnl +<0> (ls0) +]) +AT_CHECK([ovn-nbctl ls-list | uuidfilt], [0], [dnl +]) + +# Check that dry-run mode is not sticky. +AT_CHECK([ovn-nbctl ls-add ls0]) +AT_CHECK([ovn-nbctl ls-list | uuidfilt], [0], [dnl +<0> (ls0) +]) + +OVN_NBCTL_TEST_STOP +AT_CLEANUP