~upstart-devel/upstart/trunk

« back to all changes in this revision

Viewing changes to init/tests/test_state.c

  • Committer: Steve Langasek
  • Date: 2013-11-23 19:48:16 UTC
  • mto: This revision was merged to the branch mainline in revision 1577.
  • Revision ID: steve.langasek@canonical.com-20131123194816-rcjlxsfn6g06c556
fix test case to not assume SIGUSR1 == 10; the numeric value may vary
between platforms, what we actually care about is making sure that the
deserialization output matches what was in the json - so check the numeric
value, NOT the symbolic signal name.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4460
4460
        NIH_HASH_FOREACH (job_classes, iter) {
4461
4461
                JobClass *class = (JobClass *)iter;
4462
4462
                if (strcmp (class->name, "whoopsie") == 0) {
4463
 
                        TEST_EQ (class->reload_signal, SIGUSR1);
 
4463
                        TEST_EQ (class->reload_signal, 10);
4464
4464
                } else
4465
4465
                        TEST_EQ (class->reload_signal, SIGHUP);
4466
4466
        }