ci: skip UI test for PO files (#24581)

This commit is contained in:
Ankush Menat 2024-01-29 16:47:04 +05:30 committed by GitHub
parent 89e89f72d5
commit 4dce9d0d37
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -73,8 +73,9 @@ def has_label(pr_number, label, repo="frappe/frappe"):
)
def is_py(file):
return file.endswith("py")
def is_server_side_code(file):
"""File exclusively affects server side code"""
return file.endswith("py") or file.endswith(".po")
def is_ci(file):
@ -112,7 +113,7 @@ if __name__ == "__main__":
ci_files_changed = any(f for f in files_list if is_ci(f))
only_docs_changed = len(list(filter(is_docs, files_list))) == len(files_list)
only_frontend_code_changed = len(list(filter(is_frontend_code, files_list))) == len(files_list)
updated_py_file_count = len(list(filter(is_py, files_list)))
updated_py_file_count = len(list(filter(is_server_side_code, files_list)))
only_py_changed = updated_py_file_count == len(files_list)
if has_skip_ci_label(pr_number, repo):