Yes, if (and only if) the landlord expressly agreed to make repairs, then the tenant may deduct from the rent the reasonable costs of making the repairs that the landlord promised to do. Remember, in the absence of an express agreement to perform any particular repair, the landlord is not obligated to make the repair. Maintenance and repairs are the tenant's responsibility and the tenant must pay for them. Deducting the cost of repairs from the rent payment is very risky and if done without the legal right to do so, the tenant may be evicted for non-payment of rent. Before "repairing and deducting" the tenant should first discuss the matter with the landlord, then if no satisfaction is reached, get legal advice.
If the landlord has expressly promised to make repairs and has failed to fulfill that promise, the tenant has several options in addition to "repair and deduct." The tenant may be able to terminate the lease and move out of the unit without liability or may sue the landlord for damages. The tenant should always seek legal counsel before breaking a lease and moving out.