Skip to content

Commit

Permalink
Mark retyping cases as expected failure
Browse files Browse the repository at this point in the history
  • Loading branch information
nielstron committed Dec 30, 2023
1 parent b1fcf0b commit 3123243
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion opshin/tests/test_misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -1784,7 +1784,7 @@ def validator(x: Union[A, B], y: int) -> bool:
)

@hypothesis.given(a_or_b)
def test_retype_if(self, x):
def test_uniontype_if(self, x):
source_code = """
from dataclasses import dataclass
from typing import Dict, List, Union
Expand Down Expand Up @@ -1865,6 +1865,7 @@ def validator(x: Union[A, B]):
"""
builder._compile(source_code)

@unittest.expectedFailure
@hypothesis.given(a_or_b)
def test_retype_while(self, x):
source_code = """
Expand Down Expand Up @@ -1941,6 +1942,7 @@ def validator(x: Union[A, B]) -> int:
"""
builder._compile(source_code)

@unittest.expectedFailure
def test_retype(self):
source_code = """
def validator(x: int) -> str:
Expand All @@ -1950,6 +1952,7 @@ def validator(x: int) -> str:
res = eval_uplc_value(source_code, 1)
self.assertEqual(res, b"hello")

@unittest.expectedFailure
def test_retype_if_primitives(self):
source_code = """
def validator(x: int) -> str:
Expand Down

0 comments on commit 3123243

Please sign in to comment.