is_writeable also works with directories, I just tried it out and it told me whether a directory I was asking for was writeable or not.