So the date is in.
Again, I click on Select element.
It's on.
It is in the result date class CSS class.
So let's try and select that again.
It is a child of this result info element.
So let's select that.
Const date posted is equal to element.
Find result date and remember to have a dot in front because it's a CSS class.
And then we need to have the attribute of date time.
And I'm going to use that to create a new JavaScript date object.
So date time.
And then I'm going to wrap that around a new date.
So we create a new JavaScript date object.
I prefer to have my my date as a JavaScript date because it simply means that.
I can more easily get things like the month, year and so on, and rather than just having it as a string.
Um.
Okay.
So now I still have the last test is failing.
And the reason why it's a little complicated, but I'll try to explain to you.
So I'm actually getting the same date as I'm writing in here.
The date I have here, it says also received serializes to the same string.
And it says here if it should pass with deep equality, replace to B with two strict equal.
And the reason why it's failing is because there's a different difference between two objects, even
though they have the same properties.
So by that I mean if I say const date one equals new date and I have a date string here.
Could have this date string here.
And if I have one that's called day to.
And I say new date and I have exactly the same date.
If I'm going to test that and put it into a tester and say expect date one to be date two, it's going
to fail.
And the reason why it's going to fail is because in the memory of a compiler or the reference to an
object is not the same.
It's a different place in the memory, this state variable than this one.
They are different.
But they have the same properties, basically.
They're basically twins, so to say.
Um, they are identical but still different.
So the way to get around that is to simply use two strict equal, and that's going to test all of the
properties and make sure that an object has the same properties, even though it's not exactly the same
reference.
And now all of our test is passing.