From 55f6c9a2e91b0e8244d0e0094e7ec3e38b9a4a85 Mon Sep 17 00:00:00 2001 From: Ryan Leckey Date: Sun, 26 Jul 2020 18:11:15 -0700 Subject: [PATCH] test: fix decode test in macros --- tests/postgres/macros.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/postgres/macros.rs b/tests/postgres/macros.rs index 32d6cfcd..8b402491 100644 --- a/tests/postgres/macros.rs +++ b/tests/postgres/macros.rs @@ -250,8 +250,8 @@ async fn test_nullable_err() -> anyhow::Result<()> { .await .unwrap_err(); - if let sqlx::Error::Decode(err) = &err { - if let Some(sqlx::error::UnexpectedNullError) = err.downcast_ref() { + if let sqlx::Error::ColumnDecode { source, ..} = &err { + if let Some(sqlx::error::UnexpectedNullError) = source.downcast_ref() { return Ok(()); } }