void () { runInEdtAndWait(() -> { VirtualFile dir = myFS.refreshAndFindFileByIoFile(tempDir.getRoot()); assertNotNull(dir); try { WriteAction.run(() -> dir.createChildData(this, "a/b")); fail("invalid file name should have been rejected"); } catch (IOException e) { assertEquals(CoreBundle.message("file.invalid.name.error", "a/b"), e.getMessage()); } }); }