diff options
Diffstat (limited to 'tests/test-pearl-favorites.el')
| -rw-r--r-- | tests/test-pearl-favorites.el | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/test-pearl-favorites.el b/tests/test-pearl-favorites.el index 3f1452f..cb229b6 100644 --- a/tests/test-pearl-favorites.el +++ b/tests/test-pearl-favorites.el @@ -160,13 +160,17 @@ string -- the favorites query selects customView.name for exactly this." (let ((s (pearl--favorite->source (test-pearl-fav--norm 'user "user-1" "Vrezh")))) (should (equal '(:assignee-id "user-1" :open t) (plist-get s :filter))))) -(ert-deftest test-pearl-favorite->source-issue-is-browser () - "Issue favorites are browser-only in v1 (no source)." +(ert-deftest test-pearl-favorite->source-issue-renders-in-buffer () + "An issue favorite resolves to a `:type issue' source, rendered in-buffer +\(not the v1 browser punt). The identifier becomes the source name." (let ((s (pearl--favorite->source (append (test-pearl-fav--norm 'issue "iss-1" "Some bug" "https://linear.app/x/issue/ENG-1") (list :identifier "ENG-1"))))) - (should (plist-get s :browser)) - (should (string= "https://linear.app/x/issue/ENG-1" (plist-get s :url))))) + (should-not (plist-get s :browser)) + (should (eq 'issue (plist-get s :type))) + (should (string= "iss-1" (plist-get s :id))) + (should (string= "ENG-1" (plist-get s :identifier))) + (should (string= "ENG-1" (plist-get s :name))))) (ert-deftest test-pearl-favorite->source-other-is-browser () "An unknown-kind favorite is browser-only." |
