diff options
| author | Carl Hetherington <cth@carlh.net> | 2012-10-21 13:17:04 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2012-10-21 13:17:04 +0100 |
| commit | 4488ca79635bda37e034b888d1c43618f5e4285e (patch) | |
| tree | 89857796342721270a5a8f148139c2ea96c2201f /test | |
| parent | 6b368187e7bc16cbe0e83858f35990e536c5ccc8 (diff) | |
Pass options only to jobs that need them.
Diffstat (limited to 'test')
| -rw-r--r-- | test/test.cc | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/test/test.cc b/test/test.cc index 468e6c1fd..5aed18c52 100644 --- a/test/test.cc +++ b/test/test.cc @@ -426,8 +426,8 @@ BOOST_AUTO_TEST_CASE (audio_sampling_rate_test) class TestJob : public Job { public: - TestJob (shared_ptr<const FilmState> s, shared_ptr<const Options> o, Log* l, shared_ptr<Job> req) - : Job (s, o, l, req) + TestJob (shared_ptr<const FilmState> s, Log* l, shared_ptr<Job> req) + : Job (s, l, req) { } @@ -457,11 +457,10 @@ public: BOOST_AUTO_TEST_CASE (job_manager_test) { shared_ptr<const FilmState> s; - shared_ptr<const Options> o; FileLog log ("build/test/job_manager_test.log"); /* Single job, no dependency */ - shared_ptr<TestJob> a (new TestJob (s, o, &log, shared_ptr<Job> ())); + shared_ptr<TestJob> a (new TestJob (s, &log, shared_ptr<Job> ())); JobManager::instance()->add (a); dvdomatic_sleep (1); @@ -471,8 +470,8 @@ BOOST_AUTO_TEST_CASE (job_manager_test) BOOST_CHECK_EQUAL (a->finished_ok(), true); /* Two jobs, dependency */ - a.reset (new TestJob (s, o, &log, shared_ptr<Job> ())); - shared_ptr<TestJob> b (new TestJob (s, o, &log, a)); + a.reset (new TestJob (s, &log, shared_ptr<Job> ())); + shared_ptr<TestJob> b (new TestJob (s, &log, a)); JobManager::instance()->add (a); JobManager::instance()->add (b); @@ -488,8 +487,8 @@ BOOST_AUTO_TEST_CASE (job_manager_test) BOOST_CHECK_EQUAL (b->finished_ok(), true); /* Two jobs, dependency, first fails */ - a.reset (new TestJob (s, o, &log, shared_ptr<Job> ())); - b.reset (new TestJob (s, o, &log, a)); + a.reset (new TestJob (s, &log, shared_ptr<Job> ())); + b.reset (new TestJob (s, &log, a)); JobManager::instance()->add (a); JobManager::instance()->add (b); |
