Minecraft wiki entry for Durability, associated text: Breaking a block that breaks instantly counts as 0 uses.
Breaking other blocks counts as 1 use.
Paving dirt or a grass block using a shovel to make a dirt path counts as 1 use.
Using an axe on a log or wood to strip it counts as 1 use.
Hitting a mob (hostile, neutral or passive) counts as 2 uses.