From b6b0b8dd82031eb55189ad3bea5eaacd8444b9d5 Mon Sep 17 00:00:00 2001 From: Sean Allred Date: Sat, 1 Nov 2014 13:29:10 -0400 Subject: More work on data filter; add tests --- tests.el | 41 ----------------------------------------- 1 file changed, 41 deletions(-) delete mode 100644 tests.el (limited to 'tests.el') diff --git a/tests.el b/tests.el deleted file mode 100644 index 0c520d8..0000000 --- a/tests.el +++ /dev/null @@ -1,41 +0,0 @@ -(defun -stack--nuke () - (interactive) - (mapatoms - (lambda (symbol) - (if (string-prefix-p "stack-" (symbol-name symbol)) - (unintern symbol))))) - -;;; Tests - -(setq stack-core-remaining-api-requests-message-threshold 50000) -(setq debug-on-error t) - -(require 'stack-core) -(require 'stack-question) - -(ert-deftest test-basic-request () - "Test basic request functionality" - (should (stack-core-make-request "sites"))) - -(ert-deftest test-question-retrieve () - "Test the ability to receive a list of questions." - (should (stack-question-get-questions 'emacs))) - -(ert-deftest test-bad-request () - "Test a method given a bad set of keywords" - (should-error - (stack-core-make-request "questions" '(())))) - -(ert-deftest test-data-filter-1 () - "Test the meta-convenience function" - (should - (equal - '((1 . t) (2 . [1 2]) (3)) - (stack-core-filter-data '((0 . 3) - (1 . t) - (a . five) - (2 . [1 2]) - ("5" . bop) - (3) - (p . 4)) - '(1 2 3))))) -- cgit v1.2.3