So you're a med student thinking of doing residency in TX? This is how it works:
You match at a residency in Texas. Like every other residency in every other state, they'll contact you and ask you for a bunch of credentials like copy of your diploma, etc. The residency then sends all that stuff to the Texas Medical Board and arranges for you to get your Physician In Training Permit (PIT). Some residents have trouble getting their PIT and have to jump through some extra hoops, usually residents who took a year off, switched specialties, etc. If you're a typical med student, you shouldn't have a problem.
After completing 1 year of internship/residency (or 3 years for IMGs) and passing Step 3, you're eligible to apply for Physician Full Permit. This is an independent license that allows you to moonlight, get your own DEA#, etc. This is the application process that people on this board are always complaining about. It takes 6 months to a year, requires the jurisprudence exam, and costs $900 to apply, plus another $800 to register your license once it's approved. No , your residency doesn't pay for it. Some residencies require that you get your license by a certain time. (My residency requires that all eligible PGY3s be independently licensed, which gives us the whole PGY2 year for the long application process.) In any case, it would be foolish to wait until after you graduate residency to apply, because then you couldn't work during the 6-12 months it takes to get licensed.