The main test for myasthenia gravis is a blood test to look for a type of antibody (produced by the immune system) that stops signals being sent between the nerves and muscles.
A high level of these antibodies usually means you have myasthenia gravis.
But not everyone with the condition will have a high level of antibodies, particularly if it's only affecting the eye muscles (ocular myasthenia).
The blood test may be repeated at a later date if the result is normal but your symptoms continue or get worse.
If your blood test result is normal but the doctor still thinks you could have myasthenia gravis, they may suggest an electrical test of your nerves and muscles.
These tests, known as electromyography, involve inserting very small needles into your muscles to measure the electrical activity in them.
The needles are typically inserted around the eyes, in the forehead or possibly in the arms.
The electrical recordings can show whether the signals sent from the nerves to the muscles are being disrupted, which may be a sign of myasthenia gravis.
The thymus gland is a small gland in the chest that forms part of the immune system. Problems with the gland are closely associated with myasthenia gravis.
Sometimes an MRI brain scan may also be carried out to check that your symptoms are not being caused by a problem in your brain.
If it's still not clear what's causing your symptoms, the doctor may recommend a test called an edrophonium test.
It involves having an injection of a medicine called edrophonium chloride. If you have a sudden but temporary improvement in muscle strength after the injection, it's likely you have myasthenia gravis.
But this test is rarely done these days because there's a risk it could cause potentially serious side effects, such as a slow heartbeat and breathing problems.
It's only done if absolutely necessary and in a hospital setting where treatment for any side effects is readily available.