summaryrefslogtreecommitdiff
path: root/wasp/boards/simulator/test_qa.py
blob: 206e5054d028bb2529f6d26ed20651ae6fa966f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import pytest
import wasp
import os

EXCLUDE = ('Notifications', 'Template', 'Demo')

def test_screenshot(constructor):
    if constructor.NAME in EXCLUDE:
        return
    fname = f'res/{constructor.NAME}App.png'.replace(' ', '')
    assert os.path.exists(fname)

def test_screenshot_README(constructor):
    if constructor.NAME in EXCLUDE:
        return
    fname = f'res/{constructor.NAME}App.png'.replace(' ', '')
    
    with open('README.rst') as f:
        readme = f.read()
    assert fname in readme