2021-05-11 22:07:10 +02:00
|
|
|
import pytest
|
2021-05-11 22:43:56 +02:00
|
|
|
|
2021-05-11 22:07:10 +02:00
|
|
|
from pyconstants import const
|
|
|
|
|
2021-05-11 22:43:56 +02:00
|
|
|
|
2021-05-11 22:07:10 +02:00
|
|
|
def test_costant():
|
|
|
|
# It's not that complex, why am I even writing tests?
|
2021-05-11 22:43:56 +02:00
|
|
|
const.myvar = 5
|
2021-05-11 22:07:10 +02:00
|
|
|
with pytest.raises(SyntaxError):
|
|
|
|
myvar = 7
|
|
|
|
assert myvar == 5
|