Fix file mode
Fix onlyif tests