Not validating required validation drupal_validate_form is not validating required validation when i was creating a node programatically .

Can any one say, it is design like that or am i doing something wrong .

        $node_form = (object) array(
            'type' =&gt; 'MY_CONTENT_TYPE',
            'language' =&gt; LANGUAGE_NONE,
        );
        $form = drupal_get_form('application_node_form',$node_form);
        $old_fs = @unserialize($r-&gt;form_state);
        $form_state = array();
        $form_state['values'] = $old_fs['values'];
        $form_state['values']['op'] = t('Save');
        $form_state['submitted'] = 1;
        $form_state['complete form'] = array();
        $form_state['triggering_element'] = array('#parents'=&gt;array('next'),'#button_type'=&gt;'submit');
        unset($form['#token']);
        drupal_validate_form('MY_CONTENT_TYPE_node_form', $form, $form_state);
You can check if the form failed validation by calling form_get_errors

You could try using drupal_form_submit instead, which I think will also validate the form (seen via form_get_errors)