The Bible warns Christians about becoming yoked with unbelievers.
Do not be unequally yoked with unbelievers. For what partnership has righteousness with lawlessness? Or what fellowship has light with darkness? (2 Corinthians 6:14)
A good king of Judah yoked himself with unbelievers and brought disaster on his country.
King Asa died and was succeeded by his son Jehoshaphat.
Jehoshaphat his son reigned in his place and strengthened himself against Israel. He placed forces in all the fortified cities of Judah and set garrisons in the land of Judah, and in the cities of Ephraim that Asa his father had captured.
The Lord was with Jehoshaphat, because he walked in the earlier ways of his father David. He did not seek the Baals,but sought the God of his father and walked in his commandments, and not according to the practices of Israel. (2 Chronicles 17:1-4)
Jehoshaphat was obedient to God and God caused him to prosper. Then he made a tragic decision. He formed an alliance with Ahab, the king of Israel.
Now Jehoshaphat had great riches and honor, and he made a marriage alliance with Ahab. (2 Chronicles 18:1)
Here is how the Bible describes Ahab.
And Ahab the son of Omri did evil in the sight of the Lord, more than all who were before him.And as if it had been a light thing for him to walk in the sins of Jeroboam the son of Nebat, he took for his wife Jezebel the daughter of Ethbaal king of the Sidonians, and went and served Baal and worshiped him. (1 Kings 16:30,31)
Following the formation of this alliance Jehoshaphat helped Ahab wage war against Syria and Ahab was killed in battle. When Jehoshaphat returned home he received a message from God about what he had done.
Jehoshaphat the king of Judah returned in safety to his house in Jerusalem. But Jehu the son of Hanani the seer went out to meet him and said to King Jehoshaphat, “Should you help the wicked and love those who hate the LORD? Because of this, wrath has gone out against you from the LORD.
Nevertheless, some good is found in you, for you destroyed the Asheroth out of the land, and have set your heart to seek God.” (2 Chronicles 19:1-3)
After Ahab died and was succeeded by his son Ahaziah, Jehoshaphat repeated his sin and suffered the consequences.
After this Jehoshaphat king of Judah joined with Ahaziah king of Israel, who acted wickedly. He joined him in building ships to go to Tarshish, and they built the ships in Ezion-geber.
Then Eliezer the son of Dodavahu of Mareshah prophesied against Jehoshaphat, saying, “Because you have joined with Ahaziah, the Lord will destroy what you have made.” And the ships were wrecked and were not able to go to Tarshish. (2 Chronicles 20:35-37)
Jehoshaphat died and was succeeded by his son Jehoram. During his life his sin in forming alliances with Ahab and his son had resulted in his losing a battle and the loss of some ships. But the worst consequences were delayed until after his death. His alliance with Ahab was a marriage alliance. This meant that Jehoram, who was now king, was married to Athaliah the daughter of Ahab.
When Jehoram had ascended the throne of his father and was established, he killed all his brothers with the sword, and also some of the princes of Israel. Jehoram was thirty-two years old when he became king, and he reigned eight years in Jerusalem.
And he walked in the way of the kings of Israel, as the house of Ahab had done, for the daughter of Ahab was his wife. And he did what was evil in the sight of the Lord. (2 Chronicles 21:4-6)
Jehoram died and soon so did his son Ahaziah. Athaliah then took control of the country.
Now when Athaliah the mother of Ahaziah saw that her son was dead, she arose and destroyed all the royal family of the house of Judah.
But Jehoshabeath, the daughter of the king, took Joash the son of Ahaziah and stole him away from among the king’s sons who were about to be put to death, and she put him and his nurse in a bedroom. Thus Jehoshabeath, the daughter of King Jehoram and wife of Jehoiada the priest, because she was a sister of Ahaziah, hid him from Athaliah, so that she did not put him to death.
And he remained with them six years, hidden in the house of God, while Athaliah reigned over the land. (2 Chronicles 22:10-12)
If Josiah had not been rescued the Davidic line of kings would have been wiped out. After six years Jehoiada staged a coup in which Josiah was placed on the throne that was rightfully his and Athaliah was killed. When this happened the judgment for Jehoshaphat’s sin was finally over.
While Jehoshaphat was alive the consequences of his sin that he saw were relatively minor. He never saw Athaliah’s reign and her attempts to entice the people of Judah to worship Baal. If you are engaging in some kind of sinful activity you might be in the same situation he was in. You might not see any serious results of your sin. but what you are doing might be causing disastrous results beyond your awareness or in the future.