tests: Convert test for overwriting a special file to Autotest framework.