The question is a bit more complex than you might think. I'll assume you mean angular FOV.
First of all, focus distance affects the FOV (it's called "breathing"). Because of that, most specifications list angular FOV when focused to infinity, but that definition is also the least practical to measure directly.
But let's say you chose a distance you wish to measure the FOV for. Place the ruler at that distance, make sure it's long enough to cover the entire camera's image and focus the camera on the ruler. Measure the extent of the whole visible range $h$ by reading the ruler in the image and measure the distance of the ruler to the camera $d$. Then use trigonometry to calculate your FOV: $$ \alpha = 2 \arctan{\frac{h}{2d}} $$
This is a good start, but which point did you measure from? You should measure from your lens' entrance pupil, because that is the "origin" of your camera's FOV. But you most likely don't know where that entrance pupil is. For distant objects, this error should be negligible, but it matters for macro.
We actually have two unknowns (the FOV and the object distance) so we need two measurements. Without touching the focus (because this affects your FOV), move the ruler a bit closer, as close as you can while still being able to reliably read the now defocused image of the ruler. Then move as far as you can, same principle. The distance between the close and the far ruler position is $\Delta d$, and the difference in visible ruler heights is $\Delta h$. Trigonometry will get you: $$ \alpha = 2 \arctan{\frac{\Delta h}{2 \Delta d}} $$ $$ d = \frac{h}{2 \tan{(\alpha / 2)}} $$
Then you can compare the FOV you just measured with what the theory predicts ($h'$ is the sensor size, $f$ the focal distance): $$ \alpha = 2 \arctan{\frac{h'(d-f)}{2df}} $$ The measured numbers should differ from theory if your lens has significant distortions or pupil magnification, or if the lens has an internal focusing mechanism (meaning that the focal distance changes when focusing so it's not exactly known). If you knew the exact focal length and pupil magnification, the theory can account for that and you're left with just distortion.