A Calgary teacher will spend two years in federal prison for sexually exploiting one of her students.

Jennifer Mason, 28, was charged with four offences, including sexual assault and invitation to sexual touching, in connection to an incident involving a male student from the school where she was a teacher.

Mason taught at Our Lady of Assumption School in the northwest and police say that the student was 15-years-old when the contact first began so he could not consent to a sexual relationship.

The boy went on to high school but the pair continued to meet, allegedly having sex in motels and in Mason's car.

Police say the offences took place between August 2012 and November 2013.

Their relationship was discovered when homeowners called police about a couple having sex in a car parked in front of their house.

After her arrest, Mason breached her bail conditions by contacting the boy and was re-arrested in May.

Romantic text messages that Mason sent the boy while honeymooning with her new husband were read in court in front of her parents and friends.

The boy did not testify stating he is not a victim and saying he would go to jail for Mason and wants to marry her.

Through her lawyer, Mason accepted full responsibility for her actions and apologized to the boy, the families and her ex-husband.

She will spend the next two years in a federal prison and her teaching credentials will be permanently revoked in Canada.

Mason will also be a registered sex offender for the next 20 years.

(With files from Lea Williams-Doherty)