def METHOD_NAME():
    """Check we fail loading a database with an assertion"""
    path = os.path.dirname(__file__)
    try:
      cdb = CompilationDatabase.fromDirectory(path)
    except CompilationDatabaseError as e:
      assert e.cdb_error == CompilationDatabaseError.ERROR_CANNOTLOADDATABASE
    else:
      assert False