Issue #3217712 by sudiptadas19, mondrake: Replace usages of assertDirectoryNotIsWritable(), that is deprecated