They can use anything from hair follicles to nail clippings. They'll test it for the usual suspects. Mainly marijuana, cocaine/crack, heroine and meth. Alcohol only stays in your system for no more than 24 hours. But they test that with blood samples or a breathalizer. It's not against the law to drink unless that is one of your probation requirement to stay away from alcohol.
Good Luck!