In Him (Christ), you also trusted, after you heard the word of truth, the gospel of your salvation; in whom also, having believed, you were sealed with the Holy Spirit of promise, who is the guarantee of our inheritance, until the redemption of the purchased possession, to the praise of His glory. Ephesians 1:13&14 NKJV
In these verses the Holy Spirit is referred to as the Holy Spirit of promise. When Christ spoke to His disciples (John 14:1-6), He was preparing them for His departure after His work (death, burial & resurrection) was finished and His promises to them were as follows:
If you love me, keep my commandments, And I will pray the Father, and He will give you another Helper, that He may abide with you forever – the Spirit of truth, whom the world cannot receive, because it neither sees Him nor knows Him; but you know Him, for He dwells with you and will be in you. I will not leave you orphans; I will come to you (John 14:15 & 16 NKJV).
What a wonderful promise Christ makes to His disciples! The Father will send the Helper, who will be with them forever. The Helper from God comes to stay.
Messiah Jesus calls the Helper the Spirit of truth. The Lord is identifying this Helper with Himself because in John 14:6 Jesus declares: I am the way, the truth, and the life. In John 17:17 the Lord identifies the Scriptures with Himself and with the Helper when He prays as follows: Sanctify them (His disciples) by Your truth. Thy word is truth.
The Spirit of truth is not available to the world. The world cannot receive Him, because in order to receive the Spirit of truth one must receive the Messiah. The world does not see Him nor does the world know Him. The preaching of the cross is foolishness to the world, but to us who believe it is the power of God unto salvation.
Christ also promises his disciples that this Helper will not only be with them, but He will be in them. In John 14:26 the Lord identifies the Helper as the Holy Spirit, who will teach them all things and will bring to remembrance all that Christ said to them. In John 15:26 the promised Helper who comes from the Father will testify of Jesus Christ.
In John 16:5-15 the Holy Spirit of promise will not come unless the Lord Jesus goes away. When the Holy Spirit does come He will convict the world of sin, and of righteousness, and of judgment. He will guide believers into all truth. The Holy Spirit will tell of things to come. He will glorify the Lord Jesus. The Holy Spirit will take the things of Christ and teach them to His disciples. He does all this through the word of God, of which He is the author.
For the prophecy came not in old time by the will of man: but holy men of God spake as they were moved by the Holy Ghost (II Peter 1:21).
All scripture is given by inspiration of God (God breathed), and is profitable for doctrine, for reproof, for correction, for instruction in righteousness: That the man of God may be perfect (complete), throughly furnished unto all good works (II Timothy 3:16).
Note: Remember, God the Holy Spirit will never lead you contrary to Scripture. If He did, He would be a liar, but God cannot lie.
If you are being taught doctrine that is contrary to Scripture, you are being taught either the traditions of men or the doctrine of demons or both.
Doctrine that is contrary to the clear teachings of Scripture is not the doctrine of God.
Beloved, believe not every spirit, but try the spirits whether they are of God: because many false prophets are gone out into the world (I John 4:1).