Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions tools/aurora-sep/tests/test_boot_locks.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,6 @@ def lockers(self):
return (('esp-history', lambda: ESP.lock([self.boot], [self.compat])),
('m3-boot-profile', lambda: M3.locks([self.boot], 0.2, [self.compat])))

def test_defaults_name_the_compat_lock_separately(self):
self.assertEqual(ESP.BOOT_LOCK, Path('/run/lock/boot-partition.lock'))
self.assertEqual(ESP.COMPAT_LOCK, Path('/tmp/limine-global.lock'))
text = (TOOLS / 'm3-boot-profile.py').read_text()
self.assertIn("args.lock = [Path('/run/lock/boot-partition.lock')]", text)
self.assertIn("args.compat_lock = args.compat_lock or [Path('/tmp/limine-global.lock')]", text)

def test_missing_compat_lock_is_created_and_locked(self):
for name, locker in self.lockers():
with self.subTest(name):
Expand Down Expand Up @@ -170,11 +163,6 @@ def take(self, then='true'):
def probe(self, path):
return f"flock -n '{path}' true && echo free || echo busy"

def test_defaults(self):
text = ONESHOT.read_text()
self.assertIn('\nLOCKS="/run/lock/boot-partition.lock"\n', text)
self.assertIn('\nCOMPAT_LOCKS="/tmp/limine-global.lock"\n', text)

def test_missing_compat_lock_is_created_and_held(self):
r = self.take(self.probe(self.compat))
self.assertEqual(r.returncode, 0, r.stdout + r.stderr)
Expand Down
6 changes: 0 additions & 6 deletions tools/aurora-sep/tests/test_collect_handover.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
process with mode 0600, and no copy is left in the temp directory (or anywhere world-readable)
when the user's home cannot be written."""
import os
from pathlib import Path
import stat
import unittest

Expand Down Expand Up @@ -68,11 +67,6 @@ def test_an_unwritable_home_keeps_a_root_only_copy(self):
self.assertEqual(stat.S_IMODE((self.statedir / "collect").stat().st_mode) & 0o077, 0)
self.assertIn("readable by root only", proc.stdout)

def test_no_world_readable_hand_over_in_the_script(self):
text = (Path(__file__).resolve().parents[1] / "air-gpu/air-gpu-collect.sh").read_text()
self.assertNotIn("chmod 0644", text)
self.assertNotIn("mktemp --tmpdir", text)


if __name__ == "__main__":
unittest.main()
Loading