Assert that each converter has a display name.

This commit is contained in:
Manuel Friedli 2018-09-01 01:20:41 +02:00
parent a0590cc0db
commit 77c4d5831d
19 changed files with 76 additions and 0 deletions

View File

@ -9,6 +9,10 @@ describe('Base64Decoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "base64decode"', () => { it('should have the id "base64decode"', () => {
expect(sut.getId()).toEqual('base64decode'); expect(sut.getId()).toEqual('base64decode');
}); });

View File

@ -9,6 +9,10 @@ describe('Base64Encoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "base64encode"', () => { it('should have the id "base64encode"', () => {
expect(sut.getId()).toEqual('base64encode'); expect(sut.getId()).toEqual('base64encode');
}); });

View File

@ -9,6 +9,10 @@ describe('BinToDecConverter', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "bintodec"', () => { it('should have the id "bintodec"', () => {
expect(sut.getId()).toEqual('bintodec'); expect(sut.getId()).toEqual('bintodec');
}); });

View File

@ -9,6 +9,10 @@ describe('DecToBinConverter', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "dectobin"', () => { it('should have the id "dectobin"', () => {
expect(sut.getId()).toEqual('dectobin'); expect(sut.getId()).toEqual('dectobin');
}); });

View File

@ -9,6 +9,10 @@ describe('DecToHexConverter', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "dectohex"', () => { it('should have the id "dectohex"', () => {
expect(sut.getId()).toEqual('dectohex'); expect(sut.getId()).toEqual('dectohex');
}); });

View File

@ -9,6 +9,10 @@ describe('HexToDecConverter', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "hextodec"', () => { it('should have the id "hextodec"', () => {
expect(sut.getId()).toEqual('hextodec'); expect(sut.getId()).toEqual('hextodec');
}); });

View File

@ -9,6 +9,10 @@ describe('HTMLEntitiesDecoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "decodehtmlentities"', () => { it('should have the id "decodehtmlentities"', () => {
expect(sut.getId()).toEqual('decodehtmlentities'); expect(sut.getId()).toEqual('decodehtmlentities');
}); });

View File

@ -9,6 +9,10 @@ describe('HTMLEntitiesEncoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "encodehtmlentities"', () => { it('should have the id "encodehtmlentities"', () => {
expect(sut.getId()).toEqual('encodehtmlentities'); expect(sut.getId()).toEqual('encodehtmlentities');
}); });

View File

@ -18,6 +18,10 @@ describe('PunycodeDecoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "decodepunycode"', () => { it('should have the id "decodepunycode"', () => {
expect(sut.getId()).toEqual('decodepunycode'); expect(sut.getId()).toEqual('decodepunycode');
}); });

View File

@ -18,6 +18,10 @@ describe('PunycodeEncoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "encodepunycode"', () => { it('should have the id "encodepunycode"', () => {
expect(sut.getId()).toEqual('encodepunycode'); expect(sut.getId()).toEqual('encodepunycode');
}); });

View File

@ -18,6 +18,10 @@ describe('QuotedPrintableDecoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "decodequotedprintable"', () => { it('should have the id "decodequotedprintable"', () => {
expect(sut.getId()).toEqual('decodequotedprintable'); expect(sut.getId()).toEqual('decodequotedprintable');
}); });

View File

@ -18,6 +18,10 @@ describe('QuotedPrintableEncoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "encodequotedprintable"', () => { it('should have the id "encodequotedprintable"', () => {
expect(sut.getId()).toEqual('encodequotedprintable'); expect(sut.getId()).toEqual('encodequotedprintable');
}); });

View File

@ -9,6 +9,10 @@ describe('ROT13Converter', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "rot13"', () => { it('should have the id "rot13"', () => {
expect(sut.getId()).toEqual('rot13'); expect(sut.getId()).toEqual('rot13');
}); });

View File

@ -9,6 +9,10 @@ describe('URIComponentDecoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "uricomponentdecode"', () => { it('should have the id "uricomponentdecode"', () => {
expect(sut.getId()).toEqual('uricomponentdecode'); expect(sut.getId()).toEqual('uricomponentdecode');
}); });

View File

@ -9,6 +9,10 @@ describe('URIComponentEncoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "uricomponentencode"', () => { it('should have the id "uricomponentencode"', () => {
expect(sut.getId()).toEqual('uricomponentencode'); expect(sut.getId()).toEqual('uricomponentencode');
}); });

View File

@ -9,6 +9,10 @@ describe('URIDecoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "uridecode"', () => { it('should have the id "uridecode"', () => {
expect(sut.getId()).toEqual('uridecode'); expect(sut.getId()).toEqual('uridecode');
}); });

View File

@ -9,6 +9,10 @@ describe('URIEncoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "uriencode"', () => { it('should have the id "uriencode"', () => {
expect(sut.getId()).toEqual('uriencode'); expect(sut.getId()).toEqual('uriencode');
}); });

View File

@ -18,6 +18,10 @@ describe('UTF8Decoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "decodeutf8"', () => { it('should have the id "decodeutf8"', () => {
expect(sut.getId()).toEqual('decodeutf8'); expect(sut.getId()).toEqual('decodeutf8');
}); });

View File

@ -18,6 +18,10 @@ describe('UTF8Encoder', () => {
expect(sut).toBeTruthy(); expect(sut).toBeTruthy();
}); });
it('should have a display name', () => {
expect(sut.getDisplayname()).toBeTruthy();
});
it('should have the id "encodeutf8"', () => { it('should have the id "encodeutf8"', () => {
expect(sut.getId()).toEqual('encodeutf8'); expect(sut.getId()).toEqual('encodeutf8');
}); });