Swearing to something can also be referred to as vowing, pledging, or taking an oath. These terms all imply a commitment or promise to uphold a particular belief or set of values. To testify or affirm also encompasses the idea of swearing to something, particularly in a legal or formal context. Other possible synonyms include declaring, attesting, and asserting. In some cases, people may use words like guaranteeing or assuring to convey a similar sense of certainty or commitment. Ultimately, the chosen synonym will depend on the specific context and the nuances of the particular situation at hand.