@@ -20,19 +20,19 @@ describe("auro-tail", () => {
2020 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail > </ auro-tail > ` ) ) ;
2121 expect ( el . tail ) . to . equal ( "AS" ) ;
2222 expect ( el . size ) . to . equal ( "lg" ) ;
23- expect ( el . outline ) . to . be . false ;
23+ expect ( el . variant ) . to . equal ( undefined ) ;
2424 expect ( el . href ) . to . equal ( undefined ) ;
2525 } ) ;
2626
27- it ( "sets data-variant based on tail code and updates when tail changes" , async ( ) => {
27+ it ( "sets data-carrier-type based on tail code and updates when tail changes" , async ( ) => {
2828 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail tail ="AS "> </ auro-tail > ` ) ) ;
29- expect ( el . dataset . variant ) . to . equal ( "aag" ) ;
29+ expect ( el . dataset . carrierType ) . to . equal ( "aag" ) ;
3030 el . tail = "OA" ;
3131 await el . updateComplete ;
32- expect ( el . dataset . variant ) . to . equal ( "oa" ) ;
32+ expect ( el . dataset . carrierType ) . to . equal ( "oa" ) ;
3333 el . tail = "PR" ;
3434 await el . updateComplete ;
35- expect ( el . dataset . variant ) . to . equal ( "oa" ) ;
35+ expect ( el . dataset . carrierType ) . to . equal ( "oa" ) ;
3636 } ) ;
3737
3838 it ( "computes labelTypeClass per size map" , async ( ) => {
@@ -166,12 +166,12 @@ describe("auro-tail", () => {
166166 expect ( calls ) . to . equal ( 1 ) ;
167167 } ) ;
168168
169- it ( "updates variant after tail change inside same instance" , async ( ) => {
169+ it ( "updates carrierType after tail change inside same instance" , async ( ) => {
170170 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail tail ="HA "> </ auro-tail > ` ) ) ;
171- expect ( el . dataset . variant ) . to . equal ( "aag" ) ;
171+ expect ( el . dataset . carrierType ) . to . equal ( "aag" ) ;
172172 el . tail = "OA" ;
173173 await el . updateComplete ;
174- expect ( el . dataset . variant ) . to . equal ( "oa" ) ;
174+ expect ( el . dataset . carrierType ) . to . equal ( "oa" ) ;
175175 } ) ;
176176
177177 it ( "shouldShowLink false when size not in LINKS_SIZES" , async ( ) => {
@@ -199,27 +199,27 @@ describe("auro-tail", () => {
199199 expect ( el . shadowRoot . querySelector ( ".badge" ) ) . to . be . null ;
200200 } ) ;
201201
202- it ( "applies outline attribute" , async ( ) => {
203- const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail outline > </ auro-tail > ` ) ) ;
204- expect ( el . outline ) . to . be . true ;
205- expect ( el . hasAttribute ( "outline ") ) . to . be . true ;
202+ it ( "applies variant attribute" , async ( ) => {
203+ const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail variant =" outline " > </ auro-tail > ` ) ) ;
204+ expect ( el . variant ) . to . equal ( "outline" ) ;
205+ expect ( el . getAttribute ( "variant ") ) . to . equal ( "outline" ) ;
206206 } ) ;
207207
208208 it ( "returns default labelTypeClass for unmapped size" , async ( ) => {
209209 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail size ="xs "> </ auro-tail > ` ) ) ;
210210 expect ( el . labelTypeClass ) . to . equal ( "body-sm" ) ;
211211 } ) ;
212212
213- it ( "maps Hawaiian (HA) to aag variant " , async ( ) => {
213+ it ( "maps Hawaiian (HA) to aag carrierType " , async ( ) => {
214214 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail tail ="HA "> </ auro-tail > ` ) ) ;
215- expect ( el . variant ) . to . equal ( "aag" ) ;
216- expect ( el . dataset . variant ) . to . equal ( "aag" ) ;
215+ expect ( el . carrierType ) . to . equal ( "aag" ) ;
216+ expect ( el . dataset . carrierType ) . to . equal ( "aag" ) ;
217217 } ) ;
218218
219- it ( "maps unknown carrier codes to oa variant " , async ( ) => {
219+ it ( "maps unknown carrier codes to oa carrierType " , async ( ) => {
220220 const el = /** @type {AuroTail } */ ( await fixture ( html `< auro-tail tail ="XX "> </ auro-tail > ` ) ) ;
221- expect ( el . variant ) . to . equal ( "oa" ) ;
222- expect ( el . dataset . variant ) . to . equal ( "oa" ) ;
221+ expect ( el . carrierType ) . to . equal ( "oa" ) ;
222+ expect ( el . dataset . carrierType ) . to . equal ( "oa" ) ;
223223 } ) ;
224224
225225 it ( "renders slot content as label in hyperlink" , async ( ) => {
0 commit comments