Lung function test measures the amount of air breathed in and out using a device called a spirometer. It gives a measure of the maximum amount of air you can breathe out (after taking a deep breath in), as well as how much and how quickly you can breathe out.