How Does the Spirit Bear Witness that we are Children of God?

Tim talks about how one has assurance that they are a children of God and how one rests in the work of Christ and what He has done. What does it mean for the Spirit to bear witness?