Anonymous avatar Anonymous committed dfce4db

Added customize support

Comments (0)

Files changed (1)

 ;;             (local-set-key "\C-cpm" 'pytest-pdb-module)
 ;;             (local-set-key "\C-cp." 'pytest-pdb-one)))
-(defvar pytest-project-names '(""))
-(defvar pytest-project-root-files '("" ".hg" ".git"))
-(defvar pytest-project-root-test 'pytest-project-root)
-(defvar pytest-global-name "pytest")
-(defvar pytest-cmd-flags "-x")
+(defcustom pytest-project-names '("")
+  "The name of the script that starts the tests")
+(defcustom pytest-project-root-files '("" ".hg" ".git")
+  "Names of files or directories that signify the root of a
+  project")
+(defcustom pytest-project-root-test 'pytest-project-root
+  "A function used to determine the directory the tests will be
+  run from.")
+(defcustom pytest-global-name "pytest"
+  "The name of the py.test executable")
+(defcustom pytest-cmd-flags "-x"
+  "These are the flags passed to the pytest runner")
 (defun run-pytest (&optional tests debug failed)
   "run pytest"
    (let ((result
           (reduce '(lambda (x y) (or x y))
-        (mapcar 'pytest-find-test-runner-names pytest-project-names))))
+		  (mapcar 'pytest-find-test-runner-names pytest-project-names))))
      (if result
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.