simpletestauto_test_insert
Definition
simpletestauto_test_insert($node)
simpletestauto.inc, line 10
Description
Inserts test fields into table. Second step in test workflow. This function calls test server with test node id. This basically means it adds patch to test queue.
Code
<?php
function simpletestauto_test_insert($node) {
if ($node->file) {
$file = file_save_upload($node->file, file_directory_path());
$node->patch_url = file_create_url($file->filepath);
}
$etc = serialize($node->etc);
db_query("INSERT INTO {simpletestauto_test} (nid, project, patch_url, version, test_status, file_path, file_mime, file_size, issue_id, submitter, etc, test_xml) VALUES (%d, '%s', '%s', '%s', '%d', '%s', '%s', '%d', '%d', '%s', '%s', '%s')", $node->nid, $node->project, $node->patch_url,$node->version, $node->test_status, $file->filepath, $file->filemime, $file->filesize, $node->issue_id, $node->submitter, $etc, $node->test_xml);
}
?> 