No. This is assertion made in the Treaty of Versailles and is baseless. The desperate diplomatic efforts by all parties, particularly Germany make it plain that no-one wanted a war. Unfortunately the governments of each of the great powers were flailing about in an information vacuum, desperately nervous about the orders being issued in the other capital cities and terrified of being overtaken unprepared.
Austria-Hungary, as said before, had no plans for expansion or ambitions to do so. The demands made on Serbia were not unreasonable given that the heir to the Austro-Hungarian Empire had just been assassinated by an organisation with links to the Serbian Military.
Most likely the Austrians would have satisfied themselves with punishing Serbia militarily and required Serbia to resign the agreement of 1881 whereby Serbia agreed not to negotiate or sign any treaty with a third party without Austria’s approval, not to allow foreign forces on Serbia territory and to renounce permanently all claims to Bosnia-Herzegovina and the Serbian population living there. Article 2 of the 1881 treaty actually specifically said: ‘Serbia will not tolerate political, religious or other intrigues which, taking its territory as a point of departure, might be directed against the Austro-Hungarian Monarchy.’ The Serbian representatives had been happy to sign because in return the Habsburgs backed Prince Milan Obrenovic’s claim to the Serbian throne.
The Obrenovics were assassinated in 1903 by a group consisting of ultra-nationalists and members of the military who shot the royal family, hacked their bodies to pieces and threw the parts into the courtyard of the palace. One of the leaders of the coup was Colonel Dragutin Dimitrijvic, who in 1913 because the head of Serbian Military Intelligence. By 1914 he was also one of the leaders of Ujedinjenje ili Smrt (Union or Death), a Serbian organisation sworn to achieve ‘Greater Serbia’ by uniting Bosnia-Herzegovina, Montenegro, Macedonia, Croatia and Dalmatia with the Kingdom of Serbia. The Coup leaders supported Prince Petar Karadjordjevic as the new king and in return he supported Serb nationalist dreams.
Colonel Dimitrijvic probably imagined the Bosnian conspirators would just stir up trouble in Bosnia for the Habsburgs, at best possibly ferment a rebellion that expelled the Austro-Hungarians from Bosnia and led to a call for union with Serbia. The only people who seem to have had any hopes for a war were Gavrilo Princip and the other members of the Ujedinjenje ili Smrt who carried out the assasination and even then it’s doubtful, certainly they could not have imagined the war speading beyond the Balkans.