Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/tests/units/client
diff options
context:
space:
mode:
Diffstat (limited to 'tests/units/client')
-rwxr-xr-xtests/units/client/implementations.py2
-rwxr-xr-xtests/units/client/offline_routes.py2
-rwxr-xr-xtests/units/client/online_routes.py9
3 files changed, 13 insertions, 0 deletions
diff --git a/tests/units/client/implementations.py b/tests/units/client/implementations.py
index d8173e9..06902a0 100755
--- a/tests/units/client/implementations.py
+++ b/tests/units/client/implementations.py
@@ -9,6 +9,7 @@ import pickle
import shutil
import zipfile
import logging
+import hashlib
from cStringIO import StringIO
from os.path import exists, dirname
@@ -162,6 +163,7 @@ class Implementations(tests.Test):
'data': {
'unpack_size': len(activity_info),
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
},
diff --git a/tests/units/client/offline_routes.py b/tests/units/client/offline_routes.py
index ac7af1b..2300b7a 100755
--- a/tests/units/client/offline_routes.py
+++ b/tests/units/client/offline_routes.py
@@ -2,6 +2,7 @@
# sugar-lint: disable
import json
+import hashlib
from cStringIO import StringIO
from zipfile import ZipFile
from os.path import exists
@@ -311,6 +312,7 @@ class OfflineRoutes(tests.Test):
'data': {
'unpack_size': len(activity_info),
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
},
diff --git a/tests/units/client/online_routes.py b/tests/units/client/online_routes.py
index ee2efe8..6314948 100755
--- a/tests/units/client/online_routes.py
+++ b/tests/units/client/online_routes.py
@@ -7,6 +7,7 @@ import time
import copy
import shutil
import zipfile
+import hashlib
from zipfile import ZipFile
from cStringIO import StringIO
from os.path import exists, lexists, basename
@@ -666,6 +667,7 @@ Can't find all required implementations:
'data': {
'unpack_size': len(activity_info),
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
},
@@ -713,6 +715,7 @@ Can't find all required implementations:
'seqno': 5,
'unpack_size': len(activity_info),
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'blob': blob_path,
'mtime': int(os.stat(blob_path[:-5]).st_mtime),
'mime_type': 'application/vnd.olpc-sugar',
@@ -756,6 +759,7 @@ Can't find all required implementations:
'seqno': 5,
'unpack_size': len(activity_info),
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'blob': blob_path,
'mtime': int(os.stat(blob_path[:-5]).st_mtime),
'mime_type': 'application/vnd.olpc-sugar',
@@ -878,6 +882,7 @@ Can't find all required implementations:
'tags': [],
'data': {
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
'unpack_size': len(activity_info),
@@ -904,6 +909,7 @@ Can't find all required implementations:
'data': {
'blob': blob_path,
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'mime_type': 'application/vnd.olpc-sugar',
'mtime': int(os.stat(blob_path[:-5]).st_mtime),
'seqno': 5,
@@ -943,6 +949,7 @@ Can't find all required implementations:
'tags': [],
'data': {
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'unpack_size': len(activity_info),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
@@ -989,6 +996,7 @@ Can't find all required implementations:
'tags': [],
'data': {
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'unpack_size': len(activity_info),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'true'}}, 'requires': {}}},
@@ -1091,6 +1099,7 @@ Can't find all required implementations:
'tags': [],
'data': {
'blob_size': len(blob),
+ 'digest': hashlib.sha1(blob).hexdigest(),
'unpack_size': len(activity_info),
'mime_type': 'application/vnd.olpc-sugar',
'spec': {'*-*': {'commands': {'activity': {'exec': 'false'}}, 'requires': {}}},