Browse Source

test: double queare bracket in title

Junyi Du 3 years ago
parent
commit
99dc9c371c

+ 5 - 1
deps/graph-parser/test/logseq/graph_parser/text_test.cljs

@@ -101,7 +101,11 @@
   (testing "parse-property with quoted strings"
     (are [k v y] (= (parse-property k v {}) y)
          :tags "\"foo, bar\"" "\"foo, bar\""
-         :tags "\"[[foo]], [[bar]]\"" "\"[[foo]], [[bar]]\"")))
+         :tags "\"[[foo]], [[bar]]\"" "\"[[foo]], [[bar]]\""))
+  
+  (testing "parse title property with square bracket"
+    (are [k v y] (= (parse-property k v {}) y)
+      :title "[[Jan 11th, 2022]] 21:26" "\"[[Jan 11th, 2022]] 21:26\"")))
 
 
 #_(cljs.test/test-ns 'logseq.graph-parser.text-test)

+ 1 - 1
src/test/frontend/db/name_sanity_test.cljs

@@ -23,7 +23,7 @@
       (is (= file-name' file-name))
       (is (= file-name'' file-name)))))
 
-(deftest ^:focus page-name-sanitization-tests
+(deftest page-name-sanitization-tests
   (test-page-name "Some.Content!")
   (test-page-name "More _/_ Con tents")
   (test-page-name "More _________/________ Con tents")