Skip to content

Commit

Permalink
Update hello world test to v1.1.0
Browse files Browse the repository at this point in the history
It was determined [upstream] that the hello world excercise should be simplified
to always expect a return value of "Hello, World!".

[upstream]: exercism/problem-specifications#520
  • Loading branch information
benreyn committed May 16, 2018
1 parent f6512d1 commit d065609
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
6 changes: 2 additions & 4 deletions exercises/hello-world/example.el
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@

;;; Code:

(defun hello (&optional name)
"Say hello, optionally to NAME."
(let ((greetee (or name "World")))
(concat "Hello, " greetee "!")))
(defun hello ()
"Hello, World!")

(provide 'hello-world)
;;; hello-world.el ends here
7 changes: 2 additions & 5 deletions exercises/hello-world/hello-world-test.el
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
;;; hello-world-test.el --- Tests for Hello World (exercism)

;;; Commentary:
;; Common test data version: 1.1.0 be3ae66

;;; Code:

(load-file "hello-world.el")

(ert-deftest no-args ()
(ert-deftest hello-world-test ()
(should (equal (hello) "Hello, World!")))

(ert-deftest with-args ()
(should (equal (hello "Emacs") "Hello, Emacs!"))
(should (equal (hello "Exercism") "Hello, Exercism!")))

(provide 'hello-world-test)

;;; hello-world-test.el ends here

0 comments on commit d065609

Please sign in to comment.