-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conversione di progetto KR Livio : MOD_UTILS_SO
- Sostituizione delle chiamate alle WINAPI perchè non riesco a farle funzionare Test e funzionamento corretto di ListaFileEDirs e SalvaListaFile
- Loading branch information
Showing
17 changed files
with
54 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
using System; | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
using KR.NET; | ||
using System.IO; | ||
|
||
namespace KRTest | ||
{ | ||
[TestClass] | ||
public class UnitTestModUtilsSo | ||
{ | ||
[TestMethod] | ||
public void TestMethodListaFileEDirs() | ||
{ | ||
string strDirBase = "D:\\Root\\Working\\Kudalpt2019\\KRTest"; | ||
string[] strListFD = new string[5000]; int intNumLV1 = 0; | ||
MOD_UTILS_SO.ListaFileEDirs(strDirBase, strListFD, out intNumLV1); | ||
Console.Out.WriteLine("Inizio Dir List : " + strDirBase); | ||
Assert.AreEqual(2 , intNumLV1); | ||
Assert.AreEqual("Crypt" , strListFD[0]); | ||
Assert.AreEqual("Varie.txt" , strListFD[1]); | ||
for (int i = 0; i < intNumLV1; i++) | ||
{ | ||
Console.Out.WriteLine(strListFD[i]); | ||
} | ||
Console.Out.WriteLine("Fine Dir List : " + strDirBase); | ||
|
||
} | ||
|
||
[TestMethod] | ||
public void TestMethodSalvaListaFile() | ||
{ | ||
string DirBase = "D:\\Root\\Working\\Kudalpt2019\\KRTest\\"; | ||
string FileOut = DirBase + "out.txt"; | ||
string FileOutCfr = DirBase + "outCfr.txt"; | ||
MOD_UTILS_SO.SalvaListaFile(FileOut, DirBase + "Crypt\\", "", "klog.txt"); | ||
string FileOutString = File.ReadAllText(FileOut); | ||
string FileOutCfrString = File.ReadAllText(FileOutCfr); | ||
Assert.AreEqual(FileOutCfrString, FileOutString); | ||
} | ||
} | ||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
182cd823a95d2aa661c9c72da4f72760d01df655 | ||
0b8babe27e9d5eb89a2158c0abc38786f78465fd |
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.