Misc code tests