They were fought over Ferdinand's claim to the Castilian succession after the murder of King Peter of Castile in 1369.
After signing the Treaty of Salvaterra there was a period of civil war (April 1383 - August 1385 Crisis) (1383 - 1385 Portuguese interregnum) in Portugal without a ruling king.
However, to avoid the union of the two countries, this pre-nuptial agreement established the rules to the succession for the two thrones.
Therefore, it was agreed that following his death his wife, queen Leonor Telles de Menezes would assume the regency in Portugal until the son of Beatrice and John would reach 14 years old, when he would become the future king of Portugal.
The main clauses of the Treaty of Salvaterra stipulated: In the famous Cortes of Coimbra (1385), João das Regras, a lawyer supporting John Master of Aviz claims to the throne of Portugal, defended that due to a breach of the Treaty of Salvaterra, Beatrice and John I of Castile should be barred from ascending the Portuguese throne.