The clause is valid and you will be able to evict since you have kept the property of the house.
What?s not valid is to give a mortgage loan on a house belonging to the debtor and stipulate in the contract that in case of nonpayment the house will be yours automatically, without going through foreclosure proceedings (Art. 2088 of the Civil Code).
This would be one way to attack what some of the participants in the thread are doing, disguising loans as sales to avoid foreclosure. If the debtor establishes in court that the real intent of the parties was a loan agreement and not a sale, the lender will not be able to evict until the end of the foreclosure proceedings. Fortunately for the lenders, most debtors have neither the knowledge nor the funds to hire a lawyer to fight eviction in these cases.