string regex function added
This commit is contained in:
@@ -1,5 +1,10 @@
|
||||
(print (string-regex-list "<td class=\"xyz\">1</td><td>2</td>" "<td.*?>(.*?)</td>" "match" "ignore"))
|
||||
(print (string-regex-list "<td class=\"xyz\">1</td><td>2</td>" "<td.*?>(.*?)</td>" "token"))
|
||||
|
||||
|
||||
;; (include "/usr/local/var/mlisp/ut.lsp")
|
||||
;; (ut::define-test "result of (get-localtime-offset)" '(ut::assert-equal 7200 (get-localtime-offset)))
|
||||
;; (ut::define-test "result of (string-regex-list ... \"match\")" (ut::assert-equal '(("<td class=\"xyz\">1</td>" "<td>2</td>")) (string-regex-list "<td class=\"xyz\">1</td><td>2</td>" "<td.*?>(.*?)</td>" "match" "ignore")))
|
||||
;; (ut::define-test "result of (string-regex-list ... \"token\")" '(ut::assert-equal '(("1") ("2")) (string-regex-list "<td class=\"xyz\">1</td><td>2</td>" "<td.*?>(.*?)</td>" "token")))
|
||||
;; (ut::run-tests)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user