I would go get tested. Best time is when the ulcer is there so the doctor can tell. If you don't go, if it is Syphillis it may go away and get a lot worse later. They can treat this. It could be many other things depending on what it looks like. Only a doctor can really check it out. I assume you have been sexually active?
Mkh9
See a Dr to find out exactly what it is.