From 8271bf4c4d5272043677f37a65e16d21621133cb Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Sun, 21 Oct 2018 15:57:40 -0400 Subject: Make directories for the data file if needed. #721 --- coverage/control.py | 1 + 1 file changed, 1 insertion(+) (limited to 'coverage/control.py') diff --git a/coverage/control.py b/coverage/control.py index a89a9da6..2eeec85c 100644 --- a/coverage/control.py +++ b/coverage/control.py @@ -408,6 +408,7 @@ class Coverage(object): # Create the data file. We do this at construction time so that the # data file will be written into the directory where the process # started rather than wherever the process eventually chdir'd to. + ensure_dir_for_file(self.config.data_file) self._data = CoverageData( basename=self.config.data_file, suffix=suffix, -- cgit v1.2.1