aboutsummaryrefslogtreecommitdiffstats
path: root/test-data/sleep/empty/empty.py
diff options
context:
space:
mode:
Diffstat (limited to 'test-data/sleep/empty/empty.py')
-rw-r--r--test-data/sleep/empty/empty.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/test-data/sleep/empty/empty.py b/test-data/sleep/empty/empty.py
new file mode 100644
index 0000000..2bed27d
--- /dev/null
+++ b/test-data/sleep/empty/empty.py
@@ -0,0 +1,27 @@
+#!/usr/bin/env python3
+
+"""This script generates empty.sleep"""
+
+# Create file in binary mode
+f = open('empty.sleep', 'wb')
+
+# Move to begining, set size
+f.seek(0)
+f.truncate(32)
+
+# Write header, with 0xFF as the dat file type
+f.write(b'\x05\x02\x57\xFF')
+
+# Version 0
+f.write(b'\x00')
+
+# One-byte entry size
+f.write(b'\x00\x01')
+
+# No Algorithm name
+f.write(b'\x00')
+for i in range(24):
+ f.write(b'\x00')
+
+assert(f.tell() == 32)
+f.close()