Check the inside of the wheel and tire and see if you can find what punctured the tube. A spoke end could have done it. There should be a rubber rim strip over the spokes. Make sure it's intact.
When you get the new tube into the tire, inflate it just a bit to keep it from getting pinched between the rim and tire iron or tire as you slip the tire back on. Leave the valve stem nut a little loose, I usually leave mine about 1/2 way up the stem, so if the tire should slip on the rim under hard braking the stem won't get ripped off and cause a flat. This is particularly important if you run low pressures with no rim lock.
I doubt that the dealer will warranty a flat, unless you can demonstrate that the flat as caused by improper installation, but he does owe you a tube.
Bare