Browse Source

Tests fixed

pull/95/head
Sebastian Stehle 9 years ago
parent
commit
115005c0a3
  1. 2
      src/Squidex/app/framework/angular/numbers.pipes.spec.ts
  2. 3
      src/Squidex/app/shared/services/assets.service.spec.ts

2
src/Squidex/app/framework/angular/numbers.pipes.spec.ts

@ -25,6 +25,6 @@ describe('KNumberPipe', () => {
expect(pipe.transform(-1)).toBe('');
expect(pipe.transform(50)).toBe('50');
expect(pipe.transform(1024)).toBe('1k');
expect(pipe.transform(1260000)).toBe('1000k');
expect(pipe.transform(1260000)).toBe('1260k');
});
});

3
src/Squidex/app/shared/services/assets.service.spec.ts

@ -24,7 +24,7 @@ describe('AssetDto', () => {
const now = DateTime.now();
const asset_1 = new AssetDto('1', 'other', 'other', DateTime.today(), DateTime.today(), 'name.png', 'png', 1, 1, 'image/png', false, 1, 1, null);
const asset_2 = asset_1.rename('new-name', 'me', now);
const asset_2 = asset_1.rename('new-name.png', 'me', now);
expect(asset_2.fileName).toEqual('new-name.png');
expect(asset_2.lastModified).toEqual(now);
@ -256,6 +256,7 @@ describe('AssetsService', () => {
req.flush({
id: 'id1',
fileName: 'my-asset1.png',
fileType: 'png',
fileSize: 1024,
fileVersion: 2,
mimeType: 'image/png',

Loading…
Cancel
Save