1import faulthandler
2import test.support
3import unittest
4
5_xxtestfuzz = test.support.import_module('_xxtestfuzz')
6
7
8class TestFuzzer(unittest.TestCase):
9    """To keep our https://github.com/google/oss-fuzz API working."""
10
11    def test_sample_input_smoke_test(self):
12        """This is only a regression test: Check that it doesn't crash."""
13        _xxtestfuzz.run(b"")
14        _xxtestfuzz.run(b"\0")
15        _xxtestfuzz.run(b"{")
16        _xxtestfuzz.run(b" ")
17        _xxtestfuzz.run(b"x")
18        _xxtestfuzz.run(b"1")
19        _xxtestfuzz.run(b"AAAAAAA")
20        _xxtestfuzz.run(b"AAAAAA\0")
21
22
23if __name__ == "__main__":
24    faulthandler.enable()
25    unittest.main()
26