def test_attr_conflicts():
 sc = SkyCoord(1, 2, frame=u'icrs', unit=u'deg', equinox=u'J1999', obstime=u'J2001')
 SkyCoord(sc, equinox=u'J1999', obstime=u'J2001')
 SkyCoord(sc.frame, equinox=u'J1999', obstime=u'J2100')
 with pytest.raises(ValueError) as err:
  SkyCoord(sc, equinox=u'J1999', obstime=u'J2002')
 assert (u"Coordinate attribute 'obstime'=" in str(err))
 sc = SkyCoord(1, 2, frame=u'fk4', unit=u'deg', equinox=u'J1999', obstime=u'J2001')
 SkyCoord(sc, equinox=u'J1999', obstime=u'J2001')
 with pytest.raises(ValueError) as err:
  SkyCoord(sc, equinox=u'J1999', obstime=u'J2002')
 assert (u"Coordinate attribute 'obstime'=" in str(err))
 with pytest.raises(ValueError) as err:
  SkyCoord(sc.frame, equinox=u'J1999', obstime=u'J2002')
 assert (u"Coordinate attribute 'obstime'=" in str(err))

def test_attr_conflicts ( ) : sc = SkyCoord ( 1 , 2 , frame = u'icrs' , unit = u'deg' , equinox = u'J1999' , obstime = u'J2001' ) SkyCoord ( sc , equinox = u'J1999' , obstime = u'J2001' ) SkyCoord ( sc . frame , equinox = u'J1999' , obstime = u'J2100' ) with pytest . raises ( ValueError ) as err : SkyCoord ( sc , equinox = u'J1999' , obstime = u'J2002' ) assert ( u"Coordinate attribute 'obstime'=" in str ( err ) ) sc = SkyCoord ( 1 , 2 , frame = u'fk4' , unit = u'deg' , equinox = u'J1999' , obstime = u'J2001' ) SkyCoord ( sc , equinox = u'J1999' , obstime = u'J2001' ) with pytest . raises ( ValueError ) as err : SkyCoord ( sc , equinox = u'J1999' , obstime = u'J2002' ) assert ( u"Coordinate attribute 'obstime'=" in str ( err ) ) with pytest . raises ( ValueError ) as err : SkyCoord ( sc . frame , equinox = u'J1999' , obstime = u'J2002' ) assert ( u"Coordinate attribute 'obstime'=" in str ( err ) )
check conflicts resolution between coordinate attributes and init kwargs .