Mirror of https://github.com/improsocial/impro An extensible Bluesky client for web impro.social
6

Configure Feed

Select the types of activity you want to include in your feed.

Update remaining specs

Grace Kind (Dec 7, 2025, 12:39 PM EST) fe8ada1c d1c9bdd4

+41 -3
+5
tests/env.js
··· 13 13 globalThis.HTMLElement = dom.window.HTMLElement; 14 14 globalThis.customElements = dom.window.customElements; 15 15 globalThis.CustomEvent = dom.window.CustomEvent; 16 + class IntersectionObserver { 17 + observe() {} 18 + unobserve() {} 19 + } 20 + globalThis.IntersectionObserver = IntersectionObserver;
+23 -3
tests/templates/largePost.template.test.js
··· 3 3 import { largePostTemplate } from "/js/templates/largePost.template.js"; 4 4 import { post } from "../fixtures.js"; 5 5 6 + const noop = () => {}; 7 + const postInteractionHandler = { 8 + isAuthenticated: true, 9 + handleLike: noop, 10 + handleRepost: noop, 11 + handleQuotePost: noop, 12 + handleBookmark: noop, 13 + handleMuteAuthor: noop, 14 + handleBlockAuthor: noop, 15 + handleDeletePost: noop, 16 + }; 17 + 6 18 const t = new TestSuite("largePostTemplate"); 7 19 8 20 t.describe("largePostTemplate", (it) => { 9 21 it("should render the post", () => { 10 - const result = largePostTemplate({ post }); 22 + const result = largePostTemplate({ post, postInteractionHandler }); 11 23 assert(result instanceof Object); 12 24 }); 13 25 14 26 it("should render with enableClick disabled", () => { 15 - const result = largePostTemplate({ post, enableClick: false }); 27 + const result = largePostTemplate({ 28 + post, 29 + postInteractionHandler, 30 + enableClick: false, 31 + }); 16 32 assert(result instanceof Object); 17 33 }); 18 34 19 35 it("should render with reply context", () => { 20 - const result = largePostTemplate({ post, replyContext: "parent" }); 36 + const result = largePostTemplate({ 37 + post, 38 + postInteractionHandler, 39 + replyContext: "parent", 40 + }); 21 41 assert(result instanceof Object); 22 42 }); 23 43 });
+13
tests/templates/smallPost.template.test.js
··· 3 3 import { smallPostTemplate } from "/js/templates/smallPost.template.js"; 4 4 import { post } from "../fixtures.js"; 5 5 6 + const noop = () => {}; 7 + const postInteractionHandler = { 8 + isAuthenticated: true, 9 + handleLike: noop, 10 + handleRepost: noop, 11 + handleQuotePost: noop, 12 + handleBookmark: noop, 13 + handleMuteAuthor: noop, 14 + handleBlockAuthor: noop, 15 + handleDeletePost: noop, 16 + }; 17 + 6 18 const t = new TestSuite("smallPostTemplate"); 7 19 8 20 t.describe("smallPostTemplate", (it) => { 9 21 it("should render the post", () => { 10 22 const result = smallPostTemplate({ 11 23 post: post, 24 + postInteractionHandler, 12 25 }); 13 26 assert(result instanceof Object); 14 27 });