 	)
 
 
+(defun opac3-cur-file ()
+  "Return the filename (without directory) of the current buffer"
+  (file-name-nondirectory (buffer-file-name (current-buffer)))
+  )
+
 
 (defun opac3-debug-phpunit-function()
 	"Run phpunit on this function with debugger activated"
 	(interactive)
-	(opac3-compile-phpunit (cdr (phpunit-function-ap)) t)
-	)
-
-
-(defun opac3-run-phpunit()
-	"Run all phpunit tests"
-	(interactive)
-	(opac3-compile-phpunit)
+	(opac3-run-phpunit-filtered-function t)
 	)
 
 
 (defun opac3-strftime(start end) 
+	"Interprets region as a timestamp and converts into human date"
 	(interactive "r")
 	(let ((selected-text (buffer-substring start end)))
 		(geben-eval-expression (concat "strftime('%Y-%m-%d %H:%M:%S', " selected-text " )")))

	)


(defun opac3-run-last-phpunit-command()
	"Run last phpunit command"
	(interactive)
	(compile opac3-phpunit-command)
)


(defun opac3-cur-file ()
  "Return the filename (without directory) of the current buffer"
  (file-name-nondirectory (buffer-file-name (current-buffer)))
  )


(defun opac3-run-phpunit-filtered-file()
	"Run phpunit on this file / class"
	(interactive)
	(opac3-compile-phpunit (car (split-string (file-name-sans-extension (opac3-cur-file)) "Test")))
	)


(defun opac3-run-phpunit-filtered-class()
	"Run phpunit on this class"
	(interactive)
	(opac3-compile-phpunit (phpunit-class-ap))
	)


(defun opac3-run-phpunit-filtered-function()
	"Run phpunit on this function"
	(interactive)
	(opac3-compile-phpunit (cdr (phpunit-function-ap)))
	)


(defun opac3-run-phpunit-filtered-custom(custom-filter debug)

	(require 'geben)
	(require 'phpunit)
	(auto-complete-mode)
	(setq ac-sources '(ac-source-words-in-same-mode-buffers))
	(imenu-add-menubar-index)
  (setq 
	 tab-width 2
