|
97 | 97 | { |
98 | 98 | "data": { |
99 | 99 | "text/plain": [ |
100 | | - "0.013420820236206055" |
| 100 | + "0.02000713348388672" |
101 | 101 | ] |
102 | 102 | }, |
103 | 103 | "execution_count": null, |
|
186 | 186 | " files = nbglob(fname, recursive=recursive, file_re=file_re, folder_re=folder_re,\n", |
187 | 187 | " skip_file_glob=skip_file_glob, skip_file_re=skip_file_re, as_path=True, symlinks=symlinks)\n", |
188 | 188 | " files = [f.absolute() for f in sorted(files) if _keep_file(f, ignore_fname)]\n", |
189 | | - " if len(files)==0:\n", |
190 | | - " print('No files were eligible for testing')\n", |
191 | | - " return\n", |
| 189 | + " if len(files)==0: return print('No files were eligible for testing')\n", |
| 190 | + "\n", |
192 | 191 | " if n_workers is None: n_workers = 0 if len(files)==1 else min(num_cpus(), 8)\n", |
193 | 192 | " os.chdir(config_key(\"nbs_path\"))\n", |
194 | | - " results = parallel(test_nb, files, skip_flags=skip_flags, force_flags=force_flags, n_workers=n_workers, pause=pause, do_print=do_print)\n", |
| 193 | + " if IN_NOTEBOOK: kwargs = {'method':'spawn'} if os.name=='nt' else {'method':'forkserver'}\n", |
| 194 | + " else: kwargs = {}\n", |
| 195 | + " results = parallel(test_nb, files, skip_flags=skip_flags, force_flags=force_flags, n_workers=n_workers,\n", |
| 196 | + " pause=pause, do_print=do_print, **kwargs)\n", |
195 | 197 | " passed,times = zip(*results)\n", |
196 | 198 | " if all(passed): print(\"Success.\")\n", |
197 | 199 | " else: \n", |
|
240 | 242 | "name": "stdout", |
241 | 243 | "output_type": "stream", |
242 | 244 | "text": [ |
243 | | - "Starting /Users/hamel/github/nbdev/nbs/../tests/minimal.ipynb\n", |
244 | | - "- Completed /Users/hamel/github/nbdev/nbs/../tests/minimal.ipynb\n", |
245 | | - "Success.\n" |
| 245 | + "Starting /Users/jhoward/git/nbdev/nbs/../tests/minimal.ipynb\r\n", |
| 246 | + "- Completed /Users/jhoward/git/nbdev/nbs/../tests/minimal.ipynb\r\n", |
| 247 | + "Success.\r\n" |
246 | 248 | ] |
247 | 249 | } |
248 | 250 | ], |
|
268 | 270 | "name": "stdout", |
269 | 271 | "output_type": "stream", |
270 | 272 | "text": [ |
271 | | - "Starting /Users/hamel/github/nbdev/nbs/../tests/2020-02-20-test.ipynb\n", |
272 | | - "Starting /Users/hamel/github/nbdev/nbs/../tests/docs_test.ipynb\n", |
273 | | - "Starting /Users/hamel/github/nbdev/nbs/../tests/showdoc_test.ipynb\n", |
274 | | - "- Completed /Users/hamel/github/nbdev/nbs/../tests/showdoc_test.ipynb\n", |
275 | | - "- Completed /Users/hamel/github/nbdev/nbs/../tests/docs_test.ipynb\n", |
276 | | - "- Completed /Users/hamel/github/nbdev/nbs/../tests/2020-02-20-test.ipynb\n", |
| 273 | + "Starting /Users/jhoward/git/nbdev/nbs/../tests/docs_test.ipynb\n", |
| 274 | + "Starting /Users/jhoward/git/nbdev/nbs/../tests/showdoc_test.ipynb\n", |
| 275 | + "- Completed /Users/jhoward/git/nbdev/nbs/../tests/showdoc_test.ipynb\n", |
| 276 | + "- Completed /Users/jhoward/git/nbdev/nbs/../tests/docs_test.ipynb\n", |
277 | 277 | "Success.\n" |
278 | 278 | ] |
279 | 279 | } |
|
298 | 298 | "outputs": [], |
299 | 299 | "source": [ |
300 | 300 | "#|hide\n", |
301 | | - "from nbdev.doclinks import nbdev_export\n", |
302 | | - "nbdev_export()" |
| 301 | + "import nbdev; nbdev.nbdev_export()" |
303 | 302 | ] |
304 | 303 | }, |
305 | 304 | { |
|
0 commit comments