The markovgen script works as it should. I tried feeding it the entire King James Bible as a .txt file (788031 words without verse numbers and PG preambles), and this is what came out:
for thousands, forgiving iniquity and transgression and my name shall be consumed, and all thy lovers, and forgat me, saith the LORD rained upon in her treasures, saying, Who shall not see death, before he came and told the words of Solomon, to speak unto the vessels, and dwell there: behold, I will not bring against him that sent him, and kissed his feet, and rejoiced in the land of Egypt. But Pharaoh shall call it Shenir;) All the presidents and princes assembled together with him, Put forth thy hand. Be careful for us to dwell in his stead. And when they offered unto an old garment, for that which was right in the heat nor sun smite them: wouldest thou smite those whom thou persecutest: it is the man of God, little children, these things did Araunah, as a menstruous cloth; thou shalt eat in a journey, and to fight against them to the wood in order when I beheld, lo, the kings of the Manahethites. And the child of the midst of trouble, and of the righteous. But I will cause thee to curse and to Judah upon Jordan toward the inhabitants of Debir: and the goings out of her daughter. Thou art Simon the Canaanite, which dwelt in the streets. Thou hast trodden down strength. Then were the more they which have been ever the earth by the entering of the flock, lambs and goats, with water, and mar every good work, To speak evil of me. So I awoke. And he made thereunto a crown of pride, to the children of Israel. The virgin the daughter of Solomon his son, and of the earth. The mouth of it once be? The word is settled in heaven. For I verily, as absent in body, but present in Israel from everlasting to everlasting upon them all, I indeed baptize you with guile. Did I then take my master's servants, and of the earth: and they left off to build an house for the land, and the boughs thereof are consumed like smoke, and none else: and my statutes, and ye men of the day: and also furbished: It is the man before me in a charger, and given it unto the end, the same things unto the LORD. And it came to pass, as he was come out of the sons of Gershon, of the iron for things to provoke me to do? And the heavens shall give thee the secrets of men snared in holes, and they that were pleasant to the provinces, and gave it to Jerusalem; and there remained the grove that is mad, for the door of the LORD shall command the children of Hagaba, the children of Manasseh shall be no judge of the Philistines two hundred fifty and nine years in thy great and a fourth beast, which had come unto them, Whosoever shall confess that Jesus Christ is not good to eat this year thou shalt be drunken: thou shalt bless with their enchantments, and dealt unfaithfully like their bow for lies: but they shall not appear before the valley of the living child, and to the children of Akkub, the children of Asaph, came the daughters of Judah unto Jerusalem. And his disciples came to pass in Iconium, that they may not pass by me, and said, Why was not told my lord the king, and stood every man to till the beast and his violent dealing shall come from the LORD, and I felt it not: yea, I said I unto you glad tidings, how that all the chief of the rich man fade away in their place. The paths of the carcase of unclean creeping things, that have not heard that it be done through strife or vainglory; but in that time, saying, Hear ye now, O LORD my God, than to speak with the Philistines yet again spread themselves in the light, that ye stir not up, neither mollified with ointment. Your country is desolate, as overthrown by strangers. And I set before him my salvation. I said, After me cometh a great tumult he hath wrought this great people. And they made him overseer in his righteousness, and the light and my dishonour: mine adversaries are the garments of her fornication: And upon the stones of memorial in the cities of Judah were an hundred and thirty shekels, one silver charger of silver and thy flocks, and thy neighbour as thyself. On these two commandments hang all the fowls of the land? Wherefore Hanun took David's servants, and beat down the dew. My son, attend unto my lord the king my father and the carpenters, and masons: and they were written in this thing is known. Now when Jacob saw Rachel the daughter of troops: he hath promised to them that were with her at all times: his praise from the wilderness of Sinai. And they began to reign, and he reached her parched corn, and to him and to the correction of the LORD your God, and die. But he slew it; and I am King of kings: and they that hate me may see the work of pure gold shalt thou have weaned him; only the baptism that I am with you, that ye may teach their children. And ye shall return unto me that I shall not be purged from you into the hands of the nations whither I have pronounced against them: because I testify among you the Ministers of our Lord Jesus Christ be not turned back from it. It shall be changed: There is no wisdom nor understanding nor counsel from the wrath to come? Who gave himself a worthy portion; for he hath kneaded the dough, until it be confirmed, no man regarded; But ye believe not on thy gates. Seven days thou shalt have no certain dwellingplace; And labour, working with our sacrifices, and drank the wine thereof; they shall see it no more pity the poor. The is
As you can see, the names in that extract are from all over the Bible, not just the first few books of the Old Testament.
EDIT: Another way to test the script is to call its file_to_words function directly and write the output into a file:
This produces a comma-separated list of all the words in the textfile, and if the output file is longer, you can be sure it works.