From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 3A78B6EC5B; Thu, 13 May 2021 14:07:39 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 3A78B6EC5B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1620904059; bh=cZF8MmMTCDaGztI/vAzpy9tNefg1nhMWLGtgjqUaAXo=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=BguSBohUdf9z/TQekA50/aiVbivm7n0HXMtNpygv6mDscDAtojemYDkOJGyCIJNQB Mf6FyLEazGf0rwJ/4vEAsgVQF+iUQvLi93Slegjmv+n9JG8oLhkyRRogdlhLAHg2O/ vx1JzcOsFQpgc2mWS8sxXjlXdqqdHLs9hmhoJmmw= Received: from smtpng3.m.smailru.net (smtpng3.m.smailru.net [94.100.177.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id B3CB56EC5B for ; Thu, 13 May 2021 14:07:08 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B3CB56EC5B Received: by smtpng3.m.smailru.net with esmtpa (envelope-from ) id 1lh9BL-0006dS-Tp; Thu, 13 May 2021 14:07:08 +0300 To: tarantool-patches@dev.tarantool.org, olegrok@tarantool.org, yaroslav.dynnikov@tarantool.org Date: Thu, 13 May 2021 13:07:05 +0200 Message-Id: X-Mailer: git-send-email 2.24.3 (Apple Git-128) In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-7564579A: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD95978C26455E69BE022900C3053DBED76BEB47C8A8E1FDA50182A05F5380850402326DCA28494C0432A48AC9D4264B46053DD8D2FB5F70DCA08300365E2FE9C98 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7B9FBA884A7C9B8BAEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637D4360D888D8F9BE48638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D8B9D7D7CC8A7728C50BC7C6FD008C1B71117882F4460429724CE54428C33FAD305F5C1EE8F4F765FC8C7ADC89C2F0B2A5A471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F44604297287769387670735209ECD01F8117BC8BEA471835C12D1D977C4224003CC8364762BB6847A3DEAEFB0F43C7A68FF6260569E8FC8737B5C2249EC8D19AE6D49635B68655334FD4449CB9ECD01F8117BC8BEAAAE862A0553A39223F8577A6DFFEA7CE31A2885C41F97C443847C11F186F3C59DAA53EE0834AAEE X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2AD77751E876CB595E8F7B195E1C978312FAD3DE69A73763D8513B07AB14EF0B5 X-C1DE0DAB: C20DE7B7AB408E4181F030C43753B8186998911F362727C4C7A0BC55FA0FE5FC6FE9B5895C0B03521D534818D6117357E1D490DD7BCBB974B1881A6453793CE9C32612AADDFBE061C61BE10805914D3804EBA3D8E7E5B87ABF8C51168CD8EBDB5F0C88D684269EDEDC48ACC2A39D04F89CDFB48F4795C241BDAD6C7F3747799A X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34197948450CB5442ACF319F55C28820636D45FB5C117E5876C2E17753C10A10A6EA6DC3C328881C131D7E09C32AA3244C09BB48FD145EA6EE14BF408C3389A29F8894E9C85370243EFACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojoybArHp+PQUmFiZD3pJ7gw== X-Mailru-Sender: 689FA8AB762F73936BC43F508A06382234E6355CF40E4F584025685780C33C2E3841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E267EA787935ED9F1B X-Mras: Ok Subject: [Tarantool-patches] [PATCH 1/2] test: fix test output on latest Tarantool X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Vladislav Shpilevoy via Tarantool-patches Reply-To: Vladislav Shpilevoy Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Duplicate key error at insertion into a space on the latest Tarantool changed its message and it broke of the tests. The patch updates the test so it checks only the needed part of the message and does not depend on Tarantool version anymore. --- test/storage/storage.result | 8 +++++--- test/storage/storage.test.lua | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/test/storage/storage.result b/test/storage/storage.result index 2c9784a..d18b7f8 100644 --- a/test/storage/storage.result +++ b/test/storage/storage.result @@ -179,10 +179,12 @@ vshard.storage.buckets_info() status: active id: 1 ... -vshard.storage.bucket_force_create(1) -- error +ok, err = vshard.storage.bucket_force_create(1) --- -- null -- Duplicate key exists in unique index 'pk' in space '_bucket' +... +assert(not ok and err.message:match("Duplicate key exists")) +--- +- Duplicate key exists ... vshard.storage.bucket_force_drop(1) --- diff --git a/test/storage/storage.test.lua b/test/storage/storage.test.lua index 33f0498..97558f6 100644 --- a/test/storage/storage.test.lua +++ b/test/storage/storage.test.lua @@ -56,7 +56,8 @@ vshard.storage.sync(100500) vshard.storage.buckets_info() vshard.storage.bucket_force_create(1) vshard.storage.buckets_info() -vshard.storage.bucket_force_create(1) -- error +ok, err = vshard.storage.bucket_force_create(1) +assert(not ok and err.message:match("Duplicate key exists")) vshard.storage.bucket_force_drop(1) vshard.storage.buckets_info() -- 2.24.3 (Apple Git-128)