mirror of
https://github.com/bitwarden/jslib
synced 2025-12-18 01:03:26 +00:00
Add tests for domain models (#768)
This commit is contained in:
@@ -3,7 +3,6 @@ import { BaseResponse } from "../response/baseResponse";
|
||||
export class SendFileApi extends BaseResponse {
|
||||
id: string;
|
||||
fileName: string;
|
||||
key: string;
|
||||
size: string;
|
||||
sizeName: string;
|
||||
|
||||
@@ -14,7 +13,6 @@ export class SendFileApi extends BaseResponse {
|
||||
}
|
||||
this.id = this.getResponseProperty("Id");
|
||||
this.fileName = this.getResponseProperty("FileName");
|
||||
this.key = this.getResponseProperty("Key");
|
||||
this.size = this.getResponseProperty("Size");
|
||||
this.sizeName = this.getResponseProperty("SizeName");
|
||||
}
|
||||
|
||||
@@ -21,7 +21,6 @@ export class CipherData {
|
||||
favorite: boolean;
|
||||
revisionDate: string;
|
||||
type: CipherType;
|
||||
sizeName: string;
|
||||
name: string;
|
||||
notes: string;
|
||||
login?: LoginData;
|
||||
|
||||
@@ -3,7 +3,6 @@ import { SendFileApi } from "../api/sendFileApi";
|
||||
export class SendFileData {
|
||||
id: string;
|
||||
fileName: string;
|
||||
key: string;
|
||||
size: string;
|
||||
sizeName: string;
|
||||
|
||||
@@ -14,7 +13,6 @@ export class SendFileData {
|
||||
|
||||
this.id = data.id;
|
||||
this.fileName = data.fileName;
|
||||
this.key = data.key;
|
||||
this.size = data.size;
|
||||
this.sizeName = data.sizeName;
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ export class Attachment extends Domain {
|
||||
id: string;
|
||||
url: string;
|
||||
size: string;
|
||||
sizeName: string;
|
||||
sizeName: string; // Readable size, ex: "4.2 KB" or "1.43 GB"
|
||||
key: EncString;
|
||||
fileName: EncString;
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@ export class LoginUri extends Domain {
|
||||
u,
|
||||
{
|
||||
uri: null,
|
||||
match: null,
|
||||
},
|
||||
["match"]
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user