A former subpostmaster suing the Post Office has said he believed he was dismissed because he uncovered "errors" with the IT system.
Alan Bates ran the Craig-y-Don branch in Llandudno for five years.
He is one of six lead claimants in a group legal action involving more than 500 former subpostmasters which alleges the Horizon IT system contained a large number of software defects.
The Post Office denied this and said Horizon worked perfectly adequately.
Mr Bates and the other five lead claimants - Pamela Stubbs, Mohammad Sabir, Naushad Abdulla, Elizabeth Stockdale and Louise Dar, who all ran branches of the Post Office when the system was introduced - claim the system caused shortfalls in their financial accounts.
Mr Bates told the High Court he and his partner moved from West Yorkshire to Llandudno to run the post office from March 1998 to November 2003.
In a witness statement, he said: "I have little doubt that the reason for my termination is that I had not only uncovered limitations and potential errors with the Horizon system, but that I continued to question Post Office on the contractual relationship between subpostmasters and Post Office.
"We were investing much, if not all, of what we had in this venture and it was based upon a working relationship with Post Office."
The claimants said the issues led to some being made bankrupt while others were prosecuted and even jailed for offences including false accounting, fraud and theft.
They also accuse the Post Office of failing to provide adequate training to use Horizon, for failing to investigate the cause of alleged shortfalls and of misleading them about the reliability of the system.
Mr Bates said he had previously worked in the heritage and leisure sector and had experience of project management and electronic point of sale systems, which he said helped him understand "shortcomings" with Horizon.
He told the court on Thursday that he never believed he would be held responsible for financial losses that were not his fault, as "this concept seems just so unjust that I did not consider it a possibility".
The Post Office has said the claimants were trying to "rewrite" the contracts in an attempt to avoid their losses, and the burden was on the claimants to prove that any of their shortfalls were generated by flaws with Horizon.
The trial will be heard over five weeks.