From 7ea2e2362e0a4008ad2b63502f404658169b0888 Mon Sep 17 00:00:00 2001 From: Weaselbot Date: Thu, 18 Jun 2026 10:55:18 -0400 Subject: [PATCH] Apply formatting fixes from cmake-format and black Reformat the add_test call in CMakeLists.txt and collapse a multi-line json.dumps() call in test_python_bindings.py so that pre-commit passes. --- CMakeLists.txt | 7 +++---- test_python_bindings.py | 4 +--- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 517920f..41acdeb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -165,10 +165,9 @@ doctest_discover_tests(mytest WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}) find_package(Python3 COMPONENTS Interpreter) if(Python3_Interpreter_FOUND) - add_test( - NAME python_bindings - COMMAND ${Python3_EXECUTABLE} - ${CMAKE_CURRENT_SOURCE_DIR}/test_python_bindings.py) + add_test(NAME python_bindings + COMMAND ${Python3_EXECUTABLE} + ${CMAKE_CURRENT_SOURCE_DIR}/test_python_bindings.py) endif() include(CMakePushCheckState) diff --git a/test_python_bindings.py b/test_python_bindings.py index b8c9f15..5d955a9 100644 --- a/test_python_bindings.py +++ b/test_python_bindings.py @@ -73,9 +73,7 @@ def test_mixed_values(): with weaseljson.WeaselJsonParser(recorder) as parser: status = parse_all( parser, - json.dumps( - {"answer": 42, "yes": True, "no": False, "nil": None} - ).encode(), + json.dumps({"answer": 42, "yes": True, "no": False, "nil": None}).encode(), ) assert status == weaseljson.WeaselJsonStatus.OK, status