From 77255dd98e9d9c740174aa047bf3f736c1ddba54 Mon Sep 17 00:00:00 2001 From: Pi-Cla Date: Sat, 13 Apr 2024 08:15:13 +0000 Subject: [PATCH] Remove redundant use of tuple in case --- .../src/exercism_test_runner/internal.gleam | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/runner/src/exercism_test_runner/internal.gleam b/runner/src/exercism_test_runner/internal.gleam index 1cb6830..d5f3e50 100644 --- a/runner/src/exercism_test_runner/internal.gleam +++ b/runner/src/exercism_test_runner/internal.gleam @@ -84,19 +84,20 @@ pub fn print_error(error: Error, path: String, test_name: String) -> String { case error { Unequal(left, right) -> { let #(left_colored, right_colored) = case - #(dynamic.bool(left), dynamic.bool(right)) + dynamic.bool(left), + dynamic.bool(right) { - #(Ok(left_bool), Ok(right_bool)) -> #( + Ok(left_bool), Ok(right_bool) -> #( left_bool - |> string.inspect() - |> ansi.green() - |> ansi.bold(), + |> string.inspect() + |> ansi.green() + |> ansi.bold(), right_bool - |> string.inspect() - |> ansi.red() - |> ansi.bold(), + |> string.inspect() + |> ansi.red() + |> ansi.bold(), ) - _ -> { + _, _ -> { let diff = gap.to_styled(gap.compare_strings( string.inspect(left),