Yes,I always sing the piece, usually phrase by phrase as I learn it. Sometimes I play one voice part and sing another, other times sing the bass line or melody while playing the opposite part. Or just sing it without the guitar. It took me a long time to learn to do this but I believe having the music sounding in your inner ear, truly knowing what pitches come next and how the phrasing flows allows for more confidence and more musicality in playing.
So much music, so little time.