N
Novu•4w ago
Tugy

Test using storybook

Hi guys, We are using storybook to show our components and test them. do you provide a way to mock the communication from the BE so i could test our customized notification section?
11 Replies
Pawan Jain
Pawan Jain•4w ago
@Tugy Are you using @novu/notification-center or @novu/react
Tugy
TugyOP•4w ago
hey @Pawan Jain , im using @novu/react
Pawan Jain
Pawan Jain•4w ago
Thanks for sharing Tugy. Let me check with team. I will share examples if it is possible to mock
Tugy
TugyOP•4w ago
thank you @Pawan Jain me and my company are during a POV with novu so your help will be much appreciated
Pawan Jain
Pawan Jain•3w ago
@Tugy I want to check if you are building custom inbox using our hooks?
Tugy
TugyOP•3w ago
hey, yes im using your hooks and building custom notifications section (this is the direction)
No description
Tugy
TugyOP•3w ago
does all the data is communicated to the FE via http requests, or are you using sockets to transfer some of the data? if its only http then it could be mocked via MSW, but if you're using sockets then im not sure how to test this components
Novu_Bot
Novu_Bot•3w ago
@Tugy, you just advanced to level 1!
Pawan Jain
Pawan Jain•3w ago
We use socket for real time communication
Tugy
TugyOP•3w ago
ok i think ive got the answers i needed 🙂 to test the component i will use MSW to add data to the component and to check its behavior correctly, but i wont test real time communication for starters
Pawan Jain
Pawan Jain•3w ago
I have shared the feedback with team to add examples of testing custom inbox with any popular testing library
Want results from more Discord servers?
Add your server