11# SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
22#
3- # SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE
3+ # SPDX-License-Identifier: Apache-2.0
44
55"""Unit tests for Linker backend dispatch logic.
66
@@ -44,15 +44,8 @@ class TestChooseBackend:
4444 (12 , (13 , 0 ), False , False , "driver" ),
4545 ],
4646 )
47- def test_returns_expected_backend (
48- self , driver_major , nvjitlink_version , has_ltoir , lto_requested , expected
49- ):
50- assert (
51- _linker ._choose_backend (
52- driver_major , nvjitlink_version , has_ltoir , lto_requested
53- )
54- == expected
55- )
47+ def test_returns_expected_backend (self , driver_major , nvjitlink_version , has_ltoir , lto_requested , expected ):
48+ assert _linker ._choose_backend (driver_major , nvjitlink_version , has_ltoir , lto_requested ) == expected
5649
5750 @pytest .mark .parametrize (
5851 ("driver_major" , "nvjitlink_version" , "has_ltoir" , "lto_requested" , "match" ),
@@ -70,10 +63,6 @@ def test_returns_expected_backend(
7063 (12 , (13 , 0 ), False , True , "matching major versions" ),
7164 ],
7265 )
73- def test_raises_when_unsatisfiable (
74- self , driver_major , nvjitlink_version , has_ltoir , lto_requested , match
75- ):
66+ def test_raises_when_unsatisfiable (self , driver_major , nvjitlink_version , has_ltoir , lto_requested , match ):
7667 with pytest .raises (RuntimeError , match = match ):
77- _linker ._choose_backend (
78- driver_major , nvjitlink_version , has_ltoir , lto_requested
79- )
68+ _linker ._choose_backend (driver_major , nvjitlink_version , has_ltoir , lto_requested )
0 commit comments