Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
diffoscope
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
Reproducible Builds
diffoscope
Commits
56969119
Commit
56969119
authored
8 years ago
by
Chris Lamb
Browse files
Options
Downloads
Patches
Plain Diff
Device and RPM fallback comparisons needs xxd due to fixtures. (Closes: #854593)
Signed-off-by:
Chris Lamb
<
lamby@debian.org
>
parent
9d4113be
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/comparators/test_device.py
+4
-0
4 additions, 0 deletions
tests/comparators/test_device.py
tests/comparators/test_rpm.py
+1
-0
1 addition, 0 deletions
tests/comparators/test_rpm.py
with
5 additions
and
0 deletions
tests/comparators/test_device.py
+
4
−
0
View file @
56969119
...
...
@@ -24,6 +24,8 @@ from diffoscope.comparators.device import Device
from
diffoscope.comparators.utils.specialize
import
specialize
from
utils.data
import
load_fixture
,
get_data
from
utils.tools
import
skip_unless_tools_exist
text_ascii1
=
load_fixture
(
'
text_ascii1
'
)
...
...
@@ -42,10 +44,12 @@ def differences_reverse(text_ascii1, devnull):
def
test_identification
(
devnull
):
assert
isinstance
(
devnull
,
Device
)
@skip_unless_tools_exist
(
'
xxd
'
)
def
test_diff
(
differences
):
expected_diff
=
get_data
(
'
device_expected_diff
'
)
assert
differences
.
unified_diff
==
expected_diff
@skip_unless_tools_exist
(
'
xxd
'
)
def
test_diff_reverse
(
differences_reverse
):
expected_diff
=
get_data
(
'
device_expected_diff_reverse
'
)
assert
differences_reverse
.
unified_diff
==
expected_diff
This diff is collapsed.
Click to expand it.
tests/comparators/test_rpm.py
+
1
−
0
View file @
56969119
...
...
@@ -76,6 +76,7 @@ def test_content(differences):
def
test_compare_non_existing
(
monkeypatch
,
rpm1
):
assert_non_existing
(
monkeypatch
,
rpm1
)
@skip_unless_tools_exist
(
'
xxd
'
)
def
test_fallback_comparison
(
monkeypatch
):
manager
=
ComparatorManager
()
monkeypatch
.
setattr
(
manager
,
'
COMPARATORS
'
,
(
...
...
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