mohammadkaab started a new conversation Laravel Dusk Can't Run Two Tests Referring To One Page
Hi I'm writing a couple of tests with LARAVEL dusk and I've recently dumped to a new problem. well, the problem is very famous and everyone has seen it for once at least Actually I have two tests which they are calling the same page and also posting the same page. (I mean submitting the same page). The first test works as expected and the response is exactly as I want. but the second test is giving a bit different response. The response
The Page has expired due to inactivity. Please refresh and try again.
More info: When I just commented the first test the second test works as expected. so maybe the reason of the problem Is the first test. But I don't know really what should I do to make this works. Any clue guys? Thanks for any help.
I'm wondering if you have ever face such problem, I've a job and my job failed for some reasons now after 5 days I want to restart my failed_job. I'm wondering if I restart my job, does it use the old information which it was using 5 days ago, since there some sql queries and some other calculation which it's related to the database.
Thanks for any answer.
Actually I did not find the problem so far, so basically that what I've done, just changed some of the bindings in serviceProvider file so I've just put some a condition to check if it's testing env or rather something else. this solve the issue Thanks any way.
Actually I'm binding a new concrete class to an interface in one of my test classes so this way stoping the app of calling the real classes but what I'm facing it's a really funny problem. now in one of my tests I'm calling an api and that api code it's also calling a method in a different class. the problem is here that the binding it's totally working in the api code but when the api code calling a method from a different class the binding it's not working there and it's using the real class which which it's should not use.
? every one, sometimes I've noticed that laravel tries to log into wrong file and the address it's very strange
Have you every face this kind of errors ? or why this is happening ?
Logs should stay, What Do I mean with cleaning the code it's not mean to remove them, I mean to find a way to just not see them there in the Code but they actually work, let's call it behind the scene, One of my ideas it's to create an event for each of the controller action and at the end of each action Just trigger a handler according to that event. in that way, I'll extract all of the logs. But I thought maybe there is a better solution for it.
Hi everyone, I've started working on a project which increased growth in code since the customer requirements always are the most important portion of the whole process. so after one year when I'm just looking at my code I can see there are 5 places in one method which I've written Log::info, Log::error, Log::warning and That's really pain in ass when you should skip the log when you are just tracking the code and it's like hey common skip me I'm nothing. now I'm wondering somehow if you have a solution for that I mean if I can clean the code or at least extract those Logs or any mechanism you are using which I'm blind to it.