lood tests. The doctor may perform various blood tests, such as checking your red blood cell count to determine whether you have anemia, which means that you do not have enough red blood cells. He or she can also screen for H. pylori infection and pernicious anemia with blood tests.