The consent module was built testable, it just never got tested
A comment saying 'this is injectable so it can be tested outside a browser' sat there for months above a file with zero tests - and the shortest test in the file is the one that would have caught a real bug.