Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
snipper
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tuhe
snipper
Commits
3c9b11c8
Commit
3c9b11c8
authored
1 year ago
by
tuhe
Browse files
Options
Downloads
Patches
Plain Diff
Fixed test suite
parent
18b0a4c0
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/_trial_temp.lock
+1
-0
1 addition, 0 deletions
tests/_trial_temp.lock
tests/test_python.py
+18
-0
18 additions, 0 deletions
tests/test_python.py
with
19 additions
and
0 deletions
tests/_trial_temp.lock
0 → 120000
+
1
−
0
View file @
3c9b11c8
13691
\ No newline at end of file
This diff is collapsed.
Click to expand it.
tests/test_python.py
+
18
−
0
View file @
3c9b11c8
...
...
@@ -21,6 +21,24 @@ def is_same(dir1, dir2):
Compare two directory trees content.
Return False if they differ, True is they are the same.
"""
import
glob
for
f1
in
glob
.
glob
(
dir1
+
"
/**/*.*
"
):
rp
=
os
.
path
.
relpath
(
f1
,
dir1
)
f2
=
dir2
+
"
/
"
+
rp
with
open
(
f1
,
'
r
'
)
as
f
:
s1
=
f
.
read
()
with
open
(
f2
,
'
r
'
)
as
f
:
s2
=
f
.
read
()
if
s1
!=
s2
:
print
(
"
*
"
*
50
)
print
(
f1
)
print
(
s1
)
print
(
"
-
"
*
5
)
print
(
s2
)
return
False
compared
=
dircmp
(
dir1
,
dir2
)
if
(
compared
.
left_only
or
compared
.
right_only
or
compared
.
diff_files
or
compared
.
funny_files
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment