public static DomainSocket connect(String path) throws IOException {
    if (loadingFailureReason != null) {
      throw new UnsupportedOperationException(loadingFailureReason);
    }
    int fd = connect0(path);
    return new DomainSocket(path, fd);
  }
@Test(timeout=180000)
  public void testInvalidOperations() throws IOException {
    try {
      DomainSocket.connect(
        new File(sockDir.getDir(), "test_sock_invalid_operation").
          getAbsolutePath());
    } catch (IOException e) {
      GenericTestUtils.assertExceptionContains("connect(2) error: ", e);
    }
  }