In wartime; under questioning by the enemy; holding onto the truth for dear life can lead to your death.
Abraham said, "She's my sister."
Rahab said, "I don't know which way they went."
Neither of your responses had to do with fidelity to Jehovah or to Christ. These examples don’t count. But, Abraham did not lie, and Rahab misdirected murderers. Follow that through.
Furthermore, when is the last time you read the Code of Conduct for members of the U. S. Armed Forces? Do you know what the standards of that code are? Not less than the ones Peter wrongly claimed to be capable of at the time of the Crucifixion of Jesus, But he learned, didn’t he?