We treat mining as income. You are taxed for income at the market rate of the coin when you mine it and then are additionally taxed on any capital gains you make between when the coin was mined and sold. 

Did this answer your question?