Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Tests up and running.
- Loading branch information
Showing
8 changed files
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[submodule "util/ecukes"] | ||
path = util/ecukes | ||
url = https://github.com/rejeep/ecukes.git | ||
[submodule "util/espuds"] | ||
path = util/espuds | ||
url = https://github.com/rejeep/espuds.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
(provide 'buster-mode) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
Feature: Toggle deferred | ||
In order to quickly defer a test | ||
As a buster using emacs user | ||
I want to just press key please | ||
|
||
Scenario: Deferring a test | ||
When I insert: | ||
""" | ||
buster.testCase('Building Page', { | ||
"contains title after loading page": function () { | ||
assert.match(document.body.innerHTML, "Zombie TDD"); | ||
} | ||
}); | ||
""" | ||
And I go to the front of the word "assert" | ||
And I press "C-c C-b td" | ||
Then I should see "//contains" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
(When "^I go to character \"\\(.+\\)\"$" | ||
(lambda (char) | ||
(goto-char (point-min)) | ||
(let ((search (re-search-forward (format "%s" char) nil t)) | ||
(message "Can not go to character '%s' since it does not exist in the current buffer: %s")) | ||
(assert search nil message char (espuds-buffer-contents))))) | ||
|
||
(When "^I go to the \\(front\\|end\\) of the word \"\\(.+\\)\"$" | ||
(lambda (pos word) | ||
(goto-char (point-min)) | ||
(let ((search (re-search-forward (format "%s" word) nil t)) | ||
(message "Can not go to character '%s' since it does not exist in the current buffer: %s")) | ||
(assert search nil message word (espuds-buffer-contents)) | ||
(if (string-equal "front" pos) (backward-word))))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
(let* ((current-directory (file-name-directory load-file-name)) | ||
(features-directory (expand-file-name ".." current-directory)) | ||
(project-directory (expand-file-name ".." features-directory))) | ||
(setq buster-mode-root-path project-directory) | ||
(setq buster-mode-util-path (expand-file-name "util" project-directory))) | ||
|
||
(add-to-list 'load-path buster-mode-root-path) | ||
(add-to-list 'load-path (expand-file-name "espuds" buster-mode-util-path)) | ||
|
||
(require 'buster-mode) | ||
(require 'espuds) | ||
(require 'ert) | ||
|
||
(Before | ||
(switch-to-buffer | ||
(get-buffer-create "*buster-mode*")) | ||
(erase-buffer) | ||
(transient-mark-mode 1) | ||
(cua-mode 0) | ||
(setq set-mark-default-inactive nil) | ||
(deactivate-mark)) | ||
|
||
(After) |