The question of the competency of the plaintiff to testify was settled in Hayward v. French, 12 Gray, 459. The death of one of several joint contractors who are defendants does not bring the case within the exceptions to the statute, so as to render the other party incompetent. It is only the death of a sole party to a contract or cause of action in issue and on trial, or, where several joint promisors are sued, the death of all of them, that operates to exclude the other party from testifying in 1 is own favor.
*527The question of the illegality of the contract was not open to the defendant under the answer. No such ground of defence was set forth therein. Under the provisions of the practice act, any ground of defence not comprehended in a denial of the averments in the declaration must be pleaded in the answer. There is nothing in the declaration to indicate that the plaintiff’s claim was illegal or contrary to public policy. The averments in the answer set out that the plaintiff was not a public officer, but falsely pretended to be one, and thereby deceived and defrauded the defendants — a ground of defence entirely inconsistent with the allegation which the defendant sought to establish at the trial, that he was in fact clothed with official authority, and that the services he undertook to perform for the defendants were inconsistent with his public duties, and so contrary to public policy, and illegal. No such averment is contained in the answer, and the evidence offered in support of it was rightly rejected. Granger v. Ilsley, 2 Gray, 521. Bradford v. Tinkham, 6 Gray, 494.
Exceptions overruled.