Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jan 5, 2025
1 parent a9e1657 commit 9414a1e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/test_backend/test_directx/test_preprocessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
from DirectxParser import HLSLParser
from DirectxCrossGLCodeGen import HLSLToCrossGLConverter


@pytest.fixture
def converter():
return HLSLToCrossGLConverter()


def test_include_directive(converter):
shader_code = '#include "common.hlsl"\nfloat4 main() : SV_Target { return 0; }'
expected_output = (
Expand All @@ -17,8 +19,7 @@ def test_include_directive(converter):
parser = HLSLParser(tokens)
ast = parser.parse()
output = converter.convert(ast)

# Check if the included file path is part of the output
assert "// Included file: common.hlsl" in output
# Additional assertions can be added here to verify the correctness of the output

0 comments on commit 9414a1e

Please sign in to comment.