The Ninevites did good in repenting of their sinful ways, ...
True, we don't know that any of them were saved, but we also don't know that none of them were saved. So much for what we don't know.
What we do know, however, is that the people of Nineveh—generally, not universally—responded to Jonah's message with repentance. They declared a fast, put on sackcloth (a sign of mourning and repentance), and turned from their evil ways. This collective repentance extended even to the king of Nineveh, who issued a decree calling on everyone to turn from their wickedness and cry out to God for mercy.
We also know that it is God who works in the hearts of people to bring about genuine repentance. When unregenerate sinners experience true repentance, it is a result of hearing God's message and being granted the ability to recognize their sinfulness and turn toward him in humility and contrition. Genuine repentance is a demonstration of the transformative power of the Spirit.
So, here is what I see in the story of Nineveh:
1. Divine Initiative: God's message, delivered through the prophet Jonah, is the means by which God called them to repentance. The fact that they responded positively to this message should be seen as evidence of God's sovereign work in their hearts.
2. Recognition of Sinfulness: If repentance involves a recognition of one's sinfulness and a turning away from it in humility toward God, then their willingness to fast, put on sackcloth, and turn from their evil ways could demonstrate their acknowledgment of their damnable state—a recognition that must be attributed to God's work in their hearts, enabling them to see the need for repentance.
3. Humility and Contrition: If repentance involves a sense of humility and contrition—a genuine sorrow for one's sins and a desire to turn toward God—then their actions, including their fasting and wearing of sackcloth, could be viewed as signs of their contrition and humility before God.
Were any of them saved? We don't know. But we do know that nobody can genuinely repentant apart from God working in their heart, and the Ninevites appeared to genuinely repent. I think that is the most we can say, which is enough to deny that this story serves as proof that people can do things of themselves that are pleasing to God.
In all the unsaved, their good, in fact, is fraught with corruption—to the core.
Which is to say, perhaps, that their good is actually not good at all, just a better kind of sin—if such a thing can be said. The fact that an unclean spirit can go out and find seven other spirits more evil than itself (Matt 12:43-45) suggests to me that there are worse and better sins, but they are all nevertheless sins. If a corrupt good is ultimately sinful, can we just admit its sinfulness?
It is not that it's not good to refrain from evil, ...
I agree that refraining from this or that particular sin is good. But what I hear the Bible telling us is that such refraining is the work of God—that is to say, the person is not refraining
in and of himself from this or that sin. As God told Abimelech, "I have kept you from sinning against me and did not let you touch her" (Gen 20:6). If someone refrains from sinning, it is not of himself. One should not give to man the credit that belongs to God.
And we must remember that sin is a matter of the heart—which God alone can see. Not even the sinner himself can truly know how deceitful and wicked his own heart is. So, we might observe someone doing things that seem truly good, like sheltering and feeding the homeless, but what is his motivation? Is he doing it for selfish reasons (because it makes him feel better about himself) or in the name of secular humanism (which is idolatry)? Then he is not doing good but sinning. The outside of the cup might be carefully polished and gleaming, but inside is utterly filthy. Again, "If a corrupt good is ultimately sinful, can we just admit its sinfulness?"