Jason Heap was a 38-year-old former youth minister with a master's degree in divinity from Texas Christian University when he applied to become a Navy chaplain.

But the sea service rejected his application last year after he revealed plans to affiliate with the Humanist Society and the American Humanist Association, which espouses a "progressive philosophy of life that, without theism and other supernatural beliefs, affirms our ability and responsibility to lead ethical lives," according to the group's website.

The Navy's decision to reject an "atheist chaplain" is under scrutiny by a federal judge overseeing Heap's lawsuit, in which he claims the Navy violated his constitutional rights through discrimination and denial of his right to religious freedom.

The matter was argued in detail for the first time in a federal courtroom in Alexandria, Virginia, on Thursday, as a team of attorneys representing the Navy sought a summary judgment and urged District Judge James Chacheris to declare the lawsuit without merit.

The Navy claims Heap was turned away in part because of his limited experience as a religious leader, which raised questions about his ability to handle the role of providing spiritual care for thousands of sailors aboard ships at sea.

"It's a very serious job that requires a lot of experience providing religious ministry," said Kieran Gostin, an attorney representing the Defense Department and the Navy.

"It's not that [Heap] cannot practice Humanism in his private life, it's that he is not being hired by the Navy to do it in an official capacity as a chaplain."

Attorneys for Heap and the Humanist Society disagree. They believe his application for a commission was derailed because the Chaplain Accessions, Retention and Evaluation Board, or CARE Board, did not consider Humanism a legitimate religious affiliation.

× Fear of missing out? Sign up for the Early Bird Brief - a daily roundup of military and defense news stories from around the globe. Thanks for signing up. By giving us your email, you are opting in to the Early Bird Brief.

"We are not suing for a right to be a Navy chaplain. We are suing for a right to be free of religious discrimination," said Matthew Smith, one of Heap's lawyers. "His application was denied because he was endorsed by the Humanist Society, because of discrimination against the Humanist Society in violation of his constitutional rights."

Studies show about 3.6 percent of service members identify as atheists or humanists, attorneys for both sides said.

The Humanist Society trains and certifies followers to fulfill a variety of duties, including officiating at weddings in dozens of states.

When Heap was notified of his rejection in June 2014, the letter from the Navy's chief of chaplains office did not explain the ruling.

At the time, a Navy official who asked to remain anonymous said in an interview with Navy Times that there was confusion in the Chaplain Corps about what humanism really means.

"Humanism's not a defined term across the country," the official said last year. "There's a group of Jewish Humanists. The Humanist Society was once the Humanist Society of Friends, a Quaker organization."

Referring to Heap, the official went on: "I don't know that he represents a religious organization by any accepted definition."

Navy lawyers said in court on June 18 that the Defense Department has never properly ruled on whether to recognize Humanism as an official religion because no individual chaplain applicant has ever cleared the initial screening process that rejected Heap.

Smith told the federal judge that the main goal of the lawsuit was to seek "an order requiring the Armed Forces Chaplain Board to recognize the Humanist Society as an ecclesiastical endorsing agent."

Smith urged the judge overseeing the lawsuit to order Navy officials to provide sworn depositions about chaplain board policies and procedures regarding Heap's rejection.

District Judge James Cacheris said he would issue a ruling soon.