code: public static final void assertTaskUncompleted(final String processInstanceId, final String taskDefinitionKey) {
          Validate.notNull(processInstanceId);
          Validate.notNull(taskDefinitionKey);
  
          apiCallback.debug(LogMessage.TASK_1, taskDefinitionKey, processInstanceId);
          try {
              getTaskInstanceAssertable().taskIsUncompleted(processInstanceId, taskDefinitionKey);
          } catch (final AssertionError ae) {
              apiCallback.fail(ae, LogMessage.ERROR_TASK_1, taskDefinitionKey, processInstanceId);
          }
      }
docs: Asserts a task with the provided taskDefinitionKey is pending completion in the process instance with the
  provided processInstanceId.
  
  @param processInstanceId
  the process instance's id to check for. May not be <code>null</code>
  @param taskDefinitionKey
  the task's definition key to check for. May not be <code>null</code>