26 #include <scheduler.h> 54 FO_ASSERT_PTR_NULL(scheduler->
db_conn);
56 FO_ASSERT_PTR_NOT_NULL(scheduler->
db_conn);
77 FO_ASSERT_EQUAL(res, 0);
80 FO_ASSERT_EQUAL(res, 1);
97 FO_ASSERT_PTR_NULL(scheduler->
db_conn);
99 FO_ASSERT_PTR_NOT_NULL(scheduler->
db_conn);
102 FO_ASSERT_EQUAL(res, 0);
105 FO_ASSERT_EQUAL(res, -1);
123 FO_ASSERT_PTR_NULL(scheduler->
db_conn);
125 FO_ASSERT_PTR_NOT_NULL(scheduler->
db_conn);
128 FO_ASSERT_PTR_NULL(scheduler->
db_conn);
130 FO_ASSERT_PTR_NULL(scheduler->
host_url);
132 FO_ASSERT_PTR_NULL(scheduler->
sysconfig);
244 CU_TestInfo tests_scheduler[] =
PGconn * db_conn
The database connection.
int Prepare_Testing_Data(scheduler_t *scheduler)
int Prepare_Testing_Data_Scheduler(scheduler_t *scheduler)
int scheduler_daemonize(scheduler_t *scheduler)
Daemonizes the scheduler.
fo_conf * sysconfig
Configuration information loaded from the configuration file.
void scheduler_destroy(scheduler_t *scheduler)
Free any memory associated with a scheduler_t.
void database_init(scheduler_t *scheduler)
GList * host_queue
Round-robin queue for choosing which host use next.
void test_scheduler_sig_handle()
Test for scheduler_sig_handle()
void test_scheduler_clear_config()
Test for scheduler_clear_config()
gchar * host_url
The url that is used to get to the FOSSology instance.
int kill_scheduler(int force)
Kills all other running scheduler.
gint string_is_num(gchar *str)
Checks if a string is entirely composed of numeric characters.
void scheduler_clear_config(scheduler_t *scheduler)
Clears any information that is loaded when loading the configuration.
void scheduler_sig_handle(int signo)
Handles any signals sent to the scheduler that are not SIGCHLD.
scheduler_t * scheduler_init(gchar *sysconfigdir, log_t *log)
Create a new scheduler object.
void test_scheduler_daemonize()
Test for scheduler_daemonize()
void test_string_is_num()
Test for string_is_num()
void scheduler_signal(scheduler_t *scheduler)
Function that handles certain signals being delivered to the scheduler.
gchar * email_subject
The subject to be used for emails.