Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add very long line #3

Merged
merged 12 commits into from
Jun 22, 2024
8 changes: 7 additions & 1 deletion .github/workflows/format_and_lint_pr.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Format and lint code
name: Lint code
on:
pull_request:
permissions:
Expand All @@ -15,5 +15,11 @@ jobs:
python-version: '3.x'
- name: Run Black
uses: psf/black@stable
with:
options: "--check --diff -S"
- name: Install Flake8
run: |
python -m pip install --upgrade pip
pip install flake8
- name: Run Flake8
run: flake8 .
64 changes: 64 additions & 0 deletions pelicun/tests/code_repetition_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,70 @@ def all_test_files():
runs the main function to find and print repeated line blocks in each file.
"""
test_files = glob('tests/*.py')
very_long_line = [
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
1.00,
2.00,
3.00,
4.00,
5.00,
6.00,
]
very_long_string = (
'some very long thing which is some very '
'long thing which is some very long thing '
'which is some very long thing which is '
'some very long thing which is some very '
'long thing which is some very long thing '
'which is some very long thing which is '
'some very long thing which is some very '
'long thing which is some very long thing '
'which is some very long thing which is '
'very long indeed.'
)
assert very_long_line is not None
assert very_long_string is not None
for file in test_files:
print()
print(file)
Expand Down
Loading