AboutSummaryRefsLogTreeCommitDiffStats
path: root/tests/environment.scm
diff options
context:
space:
mode:
authorMathieu Lirzin <mthl@gnu.org>2018-03-23 21:50:03 +0100
committerMathieu Lirzin <mthl@gnu.org>2018-03-24 01:18:15 +0100
commitac39c00859f763933fa86d761812f37862e91b78 (patch)
treec5d4b525a488dc03f538256e480c9adafb62e50c /tests/environment.scm
parentcae2270fd72961adeae77d21d065bfcb64ca7d77 (diff)
downloadmcron-ac39c00859f763933fa86d761812f37862e91b78.tar.gz
mcron-ac39c00859f763933fa86d761812f37862e91b78.tar.bz2
mcron-ac39c00859f763933fa86d761812f37862e91b78.zip
base: Add '<schedule>' record data type
Reifying the notion of a schedule helps reasoning about the code. Passing a schedule as an argument to related procedures allows writing simpler unit tests. * src/mcron/base.scm(<schedule>): New record data type. (make-schedule, schedule-user, set-schedule-user!) (schedule-system, set-schedule-system!) (schedule-current, set-schedule-current!): New procedures. (system-job-list, user-job-list, configuration-source): Replace those global variables with ... (%global-schedule): ... this global <schedule> instance. * src/mcron/base.scm (use-system-job-list, use-user-job-list) (remove-user-jobs, clear-system-jobs, add-job, find-next-jobs) (display-schedule, run-job-loop): Add '#:SCHEDULE' keyword argument. * doc/mcron.texi (The base module): Update documentation.
Diffstat (limited to 'tests/environment.scm')
0 files changed, 0 insertions, 0 deletions