Spain’s credit rating gets upgrade thanks to rosier economy