Like the other guys are saying, it really depends on your habit. Smoking 2 weeks ago really isn't that bad if you don't smoke that often. But if you smoke a couple times per week and your last time was 2 weeks ago thats a little different story. Heres a little biochem lesson for you though:
As many of you know (specifically those of you who make pot brownies) THC is lipid (fat/oil) soluble. Thus when it enters your body the majority of the remnants are contained in your own body fat. This is why drinking ridiculous amounts of water isn't quite as effective as you may think (although it helps). When someone tells you, you need to run and "sweat" it out of your system... this doesn't actually refer to the sweat physically carrying the THC out. When you run and work out hard core you're burning and removing the fat in which the THC is bound to. So given your situation this is going to be the best way to pass your piss test.
#1 Run/bike/whatever hard core every day up until your test. I'm not talking like running a mile and calling it quits. 3-4 miles should be good. Even if you have to split it up into 2 runs. You need to feel physically tired and drained afterwards.
#2 Drink a shit ton of water. No lie, maybe 2 gallons per day. Every time you see a water source you should be drinking.
#3 Go to walmart and purchase a multi B Vitamin suppliment. Its cheap. You could get like 100 capsules with all the major B vitamins for $8.99 or something. You're going to be popping these things like tic tacs. Make sure it contains:
B1 (thiamine)
B2 (riboflavin)
B3 (niacin) ****EXTREMELY IMPORTANT****
B6 (pyridoxine)
B12 (cobalamin) ***EXTREMELY IMPORTANT***
These are all water soluble vitamins. And you can't really OD on them, because you piss the excess right out. But you should be taking 1000% - 2000% of your daily intake. B vitamins help to raise your metabolism and burn fat. Thus making all that running you're doing more effective. If your piss is lime green, its normal, no worries.
#4 Last but not least the night before your test, start drinking cranberry juice, and keep drinking it up until your test. The plan here is to dilute your piss, but still have the chemical components of the cranberry juice provide a yellow tinge to your urine so the testers wont reject the sample for being too dilute.
...but... like someone else said... it would be a fuck ton easier if you could get a friend to piss in a bag and tape it to your balls. But some places now really pat you down hard core, and some even make you piss infront of somebody watching.