| 12345678910111213141516171819202122232425262728 |
- import os
- import pytest
- from jogai import *
- def test_change_background_color_with_components_out_of_range():
- with pytest.raises(ValueError):
- sc = Scene()
- sc.change_background((-1, -1, 300))
- def test_change_background_color_with_less_components():
- with pytest.raises(ValueError):
- sc = Scene()
- sc.change_background((0, 0))
- def test_change_background_color_wrong_type():
- with pytest.raises(ValueError):
- sc = Scene()
- sc.change_background('a')
- def test_create_scene_with_wrong_type():
- with pytest.raises(TypeError):
- sc = Scene(-1)
|