open-nomad/drivers
Tim Gross 87f416943c
testing: improve fidelity of mock driver task restore (#16990)
While working on client status update improvements, I encountered problems
getting tests with the mock driver to correctly restore.

Unlike typical drivers the mock driver doesn't have an external source of truth
for whether the task is running (ex. making API calls to `dockerd` or looking
for a running PID), and so in order to make up that information, it re-parses
the original task config. But the taskrunner doesn't call the encoding step for
`RecoverTask`, only `StartTask`, so the task config the mock driver gets is
missing data.

Update the mock driver to stash the "external" state in the task state that
we'll get from the task runner, so that we don't have to try to recover from the
original `TaskConfig` anymore. This should bring the mock driver closer to the
behavior of the other drivers.
2023-04-27 11:54:10 -04:00
..
docker logs: allow disabling log collection in jobspec (#16962) 2023-04-24 10:00:27 -04:00
exec [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
java [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
mock testing: improve fidelity of mock driver task restore (#16990) 2023-04-27 11:54:10 -04:00
qemu [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
rawexec [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
shared deps: update docker to 23.0.3 (#16862) 2023-04-12 14:13:36 -05:00