A Gainsborough man who broke a restraining order by living with his partner was jailed for 12 months.
Ben Walster, 34, was arrested after police were called to a domestic disturbance at Northolme Mews in Gainsborough on December 29.
Lincoln Crown Court heard Walster asked the officers “Are you going to arrest me?” He then raised his leg but made no contact with the officer.
The court was told Walster had been made the subject of a restraining order which prevented him from living at the address in March last year.
Walster also admitted breaching a suspended prison sentence passed at Lincoln Crown Court.
David Eager, mitigating, said there had been some confusion between Walster and his partner about if the restraining order had been withdrawn.
Passing sentence Judge Simon Hirst told Walster his only option was a prison sentence.
The judge said: “On December 29 you were living with your partner in contravention of a court order.
“I accept she was perfectly happy for you to be there. But you were aggressive with the police officer, kicking out, although there was no contact.”