When you talk about a drying agent, its purpose is to remove the water in the compound. The compound NaHCO₃ can be decomposed when heated. The reaction is:
2 NaHCO₃ → Na₂CO₃ + CO₂ + H₂O
The drying agent could remove H₂O while CO₂ can escape as gas. Thus, you can determine the total amount of Na₂CO₃ in the test tube by weighing it.