[diffoscope] 01/01: Revert "Add some tests for APK comarator." - accidental commit.

Chris Lamb chris at chris-lamb.co.uk
Sun Jan 15 02:49:41 CET 2017


This is an automated email from the git hooks/post-receive script.

lamby pushed a commit to branch master
in repository diffoscope.

commit 5db4939f952246b4597c04df44684d143678af10
Author: Chris Lamb <lamby at debian.org>
Date:   Sun Jan 15 12:49:14 2017 +1100

    Revert "Add some tests for APK comarator." - accidental commit.
    
    This reverts commit e2bdcb43c0fdc96da209c7497826fa5a8bb0f883.
    
    Dch-Gbp: ignore
---
 tests/comparators/test_apk.py         |  62 ----------------------------------
 tests/data/apk_manifest_expected_diff |  11 ------
 tests/data/apk_zipinfo_expected_diff  |   6 ----
 tests/data/test1.apk                  | Bin 866 -> 0 bytes
 tests/data/test2.apk                  | Bin 864 -> 0 bytes
 5 files changed, 79 deletions(-)

diff --git a/tests/comparators/test_apk.py b/tests/comparators/test_apk.py
deleted file mode 100644
index 6253ace..0000000
--- a/tests/comparators/test_apk.py
+++ /dev/null
@@ -1,62 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# diffoscope: in-depth comparison of files, archives, and directories
-#
-# Copyright © 2017 Maria Glukhova <siammezzze at gmail.com>
-#
-# diffoscope is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# diffoscope is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with diffoscope.  If not, see <https://www.gnu.org/licenses/>.
-
-import pytest
-
-from diffoscope.comparators.apk import ApkFile
-
-from utils import skip_unless_tools_exist, data, load_fixture, \
-    assert_non_existing
-
-apk1 = load_fixture(data('test1.apk'))
-apk2 = load_fixture(data('test2.apk'))
-
-def test_identification(apk1):
-    assert isinstance(apk1, ApkFile)
-
-def test_no_differences(apk1):
-    difference = apk1.compare(apk1)
-    assert difference is None
-
- at pytest.fixture
-def differences(apk1, apk2):
-    return apk1.compare(apk2).details
-
- at skip_unless_tools_exist('apktool', 'zipinfo')
-def test_compare_non_existing(monkeypatch, apk1):
-    assert_non_existing(monkeypatch, apk1)
-
- at skip_unless_tools_exist('apktool', 'zipinfo')
-def test_zipinfo(differences):
-    assert differences[0].source1 == 'zipinfo {}'
-    assert differences[0].source2 == 'zipinfo {}'
-    expected_diff = open(data('apk_zipinfo_expected_diff')).read()
-    assert differences[0].unified_diff == expected_diff
-
- at skip_unless_tools_exist('apktool', 'zipinfo')
-def test_android_manifest(differences):
-    assert differences[1].source1 == 'AndroidManifest.xml'
-    assert differences[1].source2 == 'AndroidManifest.xml'
-    expected_diff = open(data('apk_manifest_expected_diff')).read()
-    assert differences[1].unified_diff == expected_diff
-
- at skip_unless_tools_exist('apktool', 'zipinfo')
-def test_apk_metadata_source(differences):
-    assert differences[2].source1 == 'APK metadata'
-    assert differences[2].source2 == 'APK metadata'
diff --git a/tests/data/apk_manifest_expected_diff b/tests/data/apk_manifest_expected_diff
deleted file mode 100644
index 9d37a92..0000000
--- a/tests/data/apk_manifest_expected_diff
+++ /dev/null
@@ -1,11 +0,0 @@
-@@ -1,9 +1,9 @@
- <?xml version="1.0" encoding="utf-8"?>
--<manifest android:versionCode="1" android:versionName="1.0" package="com.any.any" platformBuildVersionCode="24" platformBuildVersionName="7.0.0"
-+<manifest android:versionCode="2" android:versionName="2.0" package="com.any.any" platformBuildVersionCode="24" platformBuildVersionName="7.0.0"
-   xmlns:android="http://schemas.android.com/apk/res/android">
-     <uses-permission android:name="android.permission.INTERNET" />
-     <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
-     <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
-     <application>
-         <activity android:name="com.any.any.SomeActivity">
-             <intent-filter>
diff --git a/tests/data/apk_zipinfo_expected_diff b/tests/data/apk_zipinfo_expected_diff
deleted file mode 100644
index d1810dc..0000000
--- a/tests/data/apk_zipinfo_expected_diff
+++ /dev/null
@@ -1,6 +0,0 @@
-@@ -1,3 +1,3 @@
--Zip file size: 866 bytes, number of entries: 1
-+Zip file size: 864 bytes, number of entries: 1
- -rw----     2.0 fat     2096 bl defN 80-Jan-01 02:00 AndroidManifest.xml
--1 file, 2096 bytes uncompressed, 714 bytes compressed:  65.9%
-+1 file, 2096 bytes uncompressed, 712 bytes compressed:  66.0%
diff --git a/tests/data/test1.apk b/tests/data/test1.apk
deleted file mode 100644
index 45876d6..0000000
Binary files a/tests/data/test1.apk and /dev/null differ
diff --git a/tests/data/test2.apk b/tests/data/test2.apk
deleted file mode 100644
index 925fb42..0000000
Binary files a/tests/data/test2.apk and /dev/null differ

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/diffoscope.git


More information about the diffoscope mailing list