Skip to content

Commit

Permalink
remove interface prefix on test
Browse files Browse the repository at this point in the history
remove interface prefix on test
  • Loading branch information
previnWong committed Sep 10, 2024
1 parent f4c1e38 commit 490c9e6
Showing 1 changed file with 24 additions and 24 deletions.
48 changes: 24 additions & 24 deletions packages/common/test/resources/copyAssociatedFiles.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -553,15 +553,15 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",

describe("_sendZipsSeriallyToItem", () => {
it("handles single zip", async () => {
const zipInfos: interfaces.IZipInfo[] = [
const zipInfos: IZipInfo[] = [
{
filename: "zip1",
zip: new JSZip(),
filelist: [
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -570,14 +570,14 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
];

const copyZipIntoItemSpy = spyOn(copyZipIntoItem, "copyZipIntoItem").and.callFake(
(zipInfo: interfaces.IZipInfo) => {
return new Promise<interfaces.IZipCopyResults>((resolve) => {
(zipInfo: IZipInfo) => {
return new Promise<IZipCopyResults>((resolve) => {
resolve(_createIZipCopyResults(true, true, zipInfo.filelist));
});
},
);

const results: interfaces.IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
const results: IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
zipInfos,
"itm1234567890",
MOCK_USER_SESSION,
Expand All @@ -588,7 +588,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand All @@ -598,15 +598,15 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
});

it("handles two zips", async () => {
const zipInfos: interfaces.IZipInfo[] = [
const zipInfos: IZipInfo[] = [
{
filename: "zip1",
zip: new JSZip(),
filelist: [
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -619,7 +619,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file2",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -628,14 +628,14 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
];

const copyZipIntoItemSpy = spyOn(copyZipIntoItem, "copyZipIntoItem").and.callFake(
(zipInfo: interfaces.IZipInfo) => {
return new Promise<interfaces.IZipCopyResults>((resolve) => {
(zipInfo: IZipInfo) => {
return new Promise<IZipCopyResults>((resolve) => {
resolve(_createIZipCopyResults(true, true, zipInfo.filelist));
});
},
);

const results: interfaces.IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
const results: IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
zipInfos,
"itm1234567890",
MOCK_USER_SESSION,
Expand All @@ -646,7 +646,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand All @@ -655,7 +655,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file2",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand All @@ -665,15 +665,15 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
});

it("handles three zips", async () => {
const zipInfos: interfaces.IZipInfo[] = [
const zipInfos: IZipInfo[] = [
{
filename: "zip1",
zip: new JSZip(),
filelist: [
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -686,7 +686,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file2",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -699,7 +699,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file3",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
},
Expand All @@ -708,14 +708,14 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
];

const copyZipIntoItemSpy = spyOn(copyZipIntoItem, "copyZipIntoItem").and.callFake(
(zipInfo: interfaces.IZipInfo) => {
return new Promise<interfaces.IZipCopyResults>((resolve) => {
(zipInfo: IZipInfo) => {
return new Promise<IZipCopyResults>((resolve) => {
resolve(_createIZipCopyResults(true, true, zipInfo.filelist));
});
},
);

const results: interfaces.IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
const results: IAssociatedFileCopyResults[] = await _sendZipsSeriallyToItem(
zipInfos,
"itm1234567890",
MOCK_USER_SESSION,
Expand All @@ -726,7 +726,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file1",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand All @@ -735,7 +735,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file2",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand All @@ -744,7 +744,7 @@ describe("Module `copyAssociatedFiles`: functions for sending resources to AGO",
{
folder: "fld",
filename: "file3",
type: interfaces.EFileType.Data,
type: EFileType.Data,
mimeType: "text",
url: "http://esri.com",
fetchedFromSource: true,
Expand Down

0 comments on commit 490c9e6

Please sign in to comment.