You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
511 B
15 lines
511 B
"""Tests for license."""
|
|
|
|
import os
|
|
|
|
|
|
def test_license_present():
|
|
"""Test that the MIT license is present in the header of each module file."""
|
|
for path, _, files in os.walk("src/keycloak"):
|
|
for _file in files:
|
|
if _file.endswith(".py"):
|
|
with open(os.path.join(path, _file), "r") as fp:
|
|
content = fp.read()
|
|
assert content.startswith(
|
|
"# -*- coding: utf-8 -*-\n#\n# The MIT License (MIT)\n#\n#"
|
|
)
|