Skip to content
This repository has been archived by the owner on Jan 18, 2025. It is now read-only.

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
MikePopoloski committed May 16, 2024
1 parent add093f commit bb09661
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ requires = [
build-backend = "scikit_build_core.build"

[tool.scikit-build]
build-dir = "build/{wheel_tag}"
cmake.source-dir = "slang"
install.components = ["pylib"]
metadata.version.provider = "scikit_build_core.metadata.setuptools_scm"
Expand Down
4 changes: 2 additions & 2 deletions tests/test_basics.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@ def test_compilation():
assert (
("\n" + report)
== """
source:3:17: warning: implicit conversion truncates from 32 to 1 bits [-Wwidth-trunc]
source:3:20: warning: implicit conversion truncates from 32 to 1 bits [-Wwidth-trunc]
assign #2 o = (~i + 32'd1234);
^ ~~~~~~~~~~~~~
~ ^~~~~~~~~~~~~
"""
)

Expand Down
9 changes: 5 additions & 4 deletions tests/test_visitors.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ def test_syntax_node_visitor():
Test the SyntaxNode visitor by extracting the tokens of a SyntaxNode.
"""

tree = SyntaxTree.fromText("always (*)")
tree = SyntaxTree.fromText("always @(*)")
tokens = []

def handle(obj):
Expand All @@ -18,10 +18,11 @@ def handle(obj):
token_kinds = [t.kind for t in tokens]
assert token_kinds == [
TokenKind.AlwaysKeyword,
TokenKind.OpenParenthesisStar,
TokenKind.StarCloseParenthesis,
TokenKind.At,
TokenKind.OpenParenthesis,
TokenKind.Star,
TokenKind.CloseParenthesis,
TokenKind.Semicolon,
TokenKind.EndOfFile,
]


Expand Down

0 comments on commit bb09661

Please sign in to comment.