From the course: Replit 101: From Prompt to Product

Making sure all features work - Replit Tutorial

From the course: Replit 101: From Prompt to Product

Making sure all features work

Testing is central to app development, whether you're using AI or not. When you build an app, you need to test every piece of functionality to make sure it all works as intended and that there are no errors. Because the worst thing that can happen when you make an app is that the app isn't working the way it's supposed to, traps the user in some sort of situation they can't get out of, or isn't actually functioning as expected. Unexpected behavior needs to be caught in the testing process. So let's dig deeper into the admin interface here to make sure that everything is actually working as it's supposed to. Right now, I'm logged in as admin in an event, and there's a question being currently answered. That is controlled by this pin here. So can I unpin it by clicking? Yes, I can. Okay, that works. Let's see, can I pin it to the top again? Yes, I can. OK, so that's the functionality of I'm currently answering the question. What happens if I click Mark Answered? All right, then it disappears, and it goes over into the Answered pile down here. OK, good. Can I undo Answer? Yes, I can. If I do that, then it goes back over here. I can then pin it to the top again. OK, so this functionality works as expected. Now, can I delete one of these? Let's see. Click on Delete here. It's telling me, delete this question, OK. And the question is removed. OK, so so far, things are working. Now let's go back and see if we can create a new event. I'll go back to the front page, click on Create New Talk, and give it a talk, the new talk. And you can see here, as I put in a title, it also creates a slug for the talk. So this is the actual URL to the talk. And I can probably edit this. So yeah, so I'll just say new talk, click launch talk. It says success, talk created successfully. Yeah, it's appearing down here. All right, what happens if I click on it? Okay, here we get into the talk. There are no questions yet. Ask a question. Does this question show up in the correct talk? Post. There it is. OK, so now I can switch between talks, I guess. So welcome to live Q&A. Yes. Go into the new talk. Yes. Can I pin this to the top? OK. Mark as answered. Jumped over to answered. All right. Next step is to see, can I delete the talks? I'll click on Delete here. This cannot be undone. OK. Now the talk is deleted. I can still go back to the old one. So everything seems to be working as expected, and I can safely log out. Now, we can take this a step further by not only testing the app here inside Repl.it, but also bring it outside of Repl.it. To do that, I'll open up the app in a separate window again, then grab this URL here at the top and copy it over to my phone, and then open the app on my phone. here it is. Then from my phone I want to see if I can add something to the app and then see it appear over here and vice versa. So I'll go into the current event and then I'll also go into the event here and then I'll add a new question, so I'll go ask Morten on his phone does this question show up post question so it's appearing here and it's appearing there meaning the two are connected so then the question is if I change this view here does it also change on my phone? No, it does not. So now we have the reason view over there, we have the popular view here. What happens if I log in? So I'll go back to admin, log back in, oops, log back in, then go into the talk here, and I will delete the comment I just made. So it's sitting here, does this question show up? I'll delete it. Let's see if it disappears. And it does. Okay, so this app is actually working across two devices independently, and the functionality is there the way I want it to be. Which, to be honest, is really impressive because getting this to work is not straightforward.

Contents