In case the action be brought by some one of several persons entitled as joint tenants, tenants in common, or coparceners, any joint tenant, tenant in common, or coparcener defending the action, may give notice with his answer or other defense that he admits the right of the plaintiff to an undivided share of the property, stating what share, but denies any actual ouster of him from the property. Upon the trial of the issue, if it appear that the defendant is a joint tenant, tenant in common, or coparcener with the plaintiff, and actual ouster shall not be proved, then the plaintiff shall be involuntarily dismissed, with costs. But if it be proved either that the defendant is not a joint tenant, tenant in common, or coparcener, or that an actual ouster had taken place, then the jury shall so find by the verdict, and the plaintiff shall have judgment in accordance with the verdict for the recovery of possession and costs.