1
00:00:01,770 --> 00:00:05,790
So we've made some changes to our code base, and any time you do that, it's always a good idea to

2
00:00:05,790 --> 00:00:08,240
run your tests just to make sure everything still works.

3
00:00:08,640 --> 00:00:14,340
So let's open a terminal and I mean the root level of my project, and I'm going to run the tests for

4
00:00:14,340 --> 00:00:15,390
the entire project.

5
00:00:15,390 --> 00:00:22,710
And I can do that just by going go test V for verbose run the tests in this directory and in all the

6
00:00:22,710 --> 00:00:26,420
lower directories or all the directories beneath this one of those three dot means.

7
00:00:27,180 --> 00:00:35,940
So let's run them and we have a fail and the fail is right here on line.

8
00:00:35,940 --> 00:00:37,730
One hundred and forty eight of handlers thought go.

9
00:00:37,740 --> 00:00:38,670
Let's see what that is.

10
00:00:40,380 --> 00:00:44,340
So line 140 over writing to the error log from the app.

11
00:00:44,640 --> 00:00:46,770
And if you recall in Maine, don't go.

12
00:00:47,130 --> 00:00:51,660
We actually assigned these two logger's to our application config.

13
00:00:51,870 --> 00:00:55,110
So we need to add them in our setup test for the handlers package.

14
00:00:55,290 --> 00:00:55,950
And that's easy.

15
00:00:55,950 --> 00:01:03,180
I just copy and paste and I have to change the equals to a sign which will work just fine.

16
00:01:04,050 --> 00:01:05,580
And I'll let's run that test again.

17
00:01:05,580 --> 00:01:11,000
So I'll clear the screen and I'll run the tests and everything passed.

18
00:01:11,010 --> 00:01:14,250
Now this error log here can't get error from the session.

19
00:01:14,280 --> 00:01:14,910
That's fine.

20
00:01:15,210 --> 00:01:20,070
That's actually being generated by the line that was causing us problems before and that's fine for

21
00:01:20,070 --> 00:01:20,490
right now.

22
00:01:20,490 --> 00:01:23,480
We'll worry about that when we actually have our database hooked up.

23
00:01:23,970 --> 00:01:30,570
So since we've added it to the setup test for handlers, let's also add it for for the setup test in

24
00:01:31,350 --> 00:01:32,370
our render package.

25
00:01:33,360 --> 00:01:37,860
So in here, if you recall, I didn't call it app, I called it test app, but I'll just paste it in

26
00:01:38,460 --> 00:01:40,200
and change this to test app

27
00:01:43,800 --> 00:01:50,100
and we'll run the tests again just to make sure they all pass and everything passes.

28
00:01:50,370 --> 00:01:51,100
So that's great.

29
00:01:51,330 --> 00:01:55,260
So this is something you should keep in mind any time you make a change to your code code base, it's

30
00:01:55,260 --> 00:01:59,190
a really good idea to run your tests and just make sure that everything is up to date.

31
00:01:59,910 --> 00:02:03,510
And if you leave it for too long, updating your test becomes a real chore.

32
00:02:03,510 --> 00:02:04,830
So do it regularly.

33
00:02:04,830 --> 00:02:10,050
Any time you change your code base after you think you're done, run your tests and update them as necessary.
