Ron Williams knew something was amiss when his six-year-old son came home from his public school in Queensland singing gospel ditties. A jazz singer, composer and father of six, Williams discovered that his son was taking his cues from the school chaplain – one of thousands installed in Australia's public schools at public expense. Williams and his wife Andrea, who was inculcated in fundamentalist faith at school, asked the school to keep their son out of the chaplain's classes. When the other kids found out, they began to taunt him, telling him he would go to hell.

One of the Williams's older children later came home with a "Biblezine", which the school chaplain had handed out to all 1,500 students at the school. The magazine promoted a distinctly fundamentalist religious take on sexuality and relationships. "Condoms … promote promiscuity," one article stated. "God doesn't call it alternative lifestyle," another article said of same-sex relationships. "He calls it a sin."

Constitutions matter; courts sometimes matter more. Australia's constitution has been said to lack clarity on the separation of church and state, and its high court has made a murky situation muddy over the past decades, with rulings that have undermined the secular character of the Commonwealth. The Australian constitution does have a clause that forbids the Commonwealth from making any law "for" establishing "any" religion. By way of contrast, the first amendment of the US constitution, which served as a model for the Australians in this instance, says Congress shall make no law "respecting an establishment of religion". In 1981, the high court justices, relying in part on a sophisticated reading of the words "for" and "any", concluded that Australia's constitution does not in fact guarantee the separation of church and state. They therefore upheld a programme that funnelled – and still does – taxpayer money to religious schools that operate largely free from public scrutiny.

In 2001, Australian politics took a rightward turn and in 2006 the conservative Howard government decided that the state should pay for religion in public schools. Thus was born the National School Chaplaincy Programme. There are almost 3,000 such chaplains in Australian public schools, and the programme is expanding under the Labor government. Although many religious affiliations can be found in Australia, the overwhelming majority of its chaplains belong to evangelical Christian sects.

Exactly what chaplains are supposed to do is unclear. Guidelines suggest they are expected to provide spiritual guidance to the children, but at the same time it prohibits them from proselytising or from offering psychological counselling. Much evidence suggests that many of the chaplains in fact do both.

When Northern Territory mother Cathy Cross's nine-year-old son, Aidan, started exhibiting signs of stress, she asked the school for help. Five months after the initial request, she learned that her troubled son was not seeing a trained therapist, but a school chaplain with no relevant qualifications. She was outraged, and an ombudsman concluded that the case involved a serious breach of the programme guidelines. David Stokes, senior manager of professional practice at the Australian psychological society, considers the chaplaincy programme dangerous. "We find this an absolute misuse of funds to put resources into people who are misequipped to handle the sorts of situations in schools," he says. "They have stepped over that professional boundary very regularly." Even the Anglican church has its doubts.

Beau Walker, a young man who served recently as a school chaplain, admits he had "no training" and felt entirely unprepared to deal with children suffering from traumatic events, such as the loss of family members. "The guidelines say no counselling, but what else can you do?" he says. The chaplains aren't supposed to teach, but some have become involved in instruction activities. At Gympie State school in Queensland, the chaplain organised an attendance-optional lunchtime "science lecture". The presentation featured John Mackay, an avowed creationist who maintains that dinosaurs co-existed with human beings.

Defenders of the programme point out that the chaplains are well-liked by most kids and that they provide support for children going through family or personal troubles. All that may be true, but it begs the question: if the state thinks the children need psychological support, why doesn't it hire people trained to offer it? The chaplaincy programme presents itself as an investment in education, but in fact it is a diversion of resources from education to religion.

In November 2009, the Williamses decided to sue. In exercising their rights to intervene, the states of New South Wales, Victoria, Queensland, South Australia, Western Australia and Tasmania concurred with a key argument pertaining to states' rights put forward by the Williamses in the case. A decision could be months, or even days, away.

Americans might, at first glance, take pride in the US constitution and in the interpretation of that constitution as enshrined in supreme court decisions, such as that in the 1947 case Everson v Board of Education, which require a clear separation of church and school. But on second glance, Americans should find cause for concern. Over the past two decades, the conservative majority on the US supreme court has systematically undermined the establishment clause as it relates to public schools. We don't have school chaplains yet, but we do allow programmes in the schools that allow outside adults to pretend to young children that is more or less what they are. The state funding of religious schools remains technically unconstitutional in America – but the court now tells us that voucher programmes that have the same effect are not.

Trends eroding the separation of church and state are global in nature. In a world of escalating income inequality, it is perhaps to be expected that some powerful forces will be interested in replacing education with religion, and religious fundamentalism appears to be rising to meet the need. The high court's decision will ultimately be about the law in Australia, but it might also give us a reading on the state of the world.

• Follow Comment is free on Twitter @commentisfree