本文整理汇总了C#中SS.Spreadsheet.GetSavedVersion方法的典型用法代码示例。如果您正苦于以下问题:C# Spreadsheet.GetSavedVersion方法的具体用法?C# Spreadsheet.GetSavedVersion怎么用?C# Spreadsheet.GetSavedVersion使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SS.Spreadsheet
的用法示例。
在下文中一共展示了Spreadsheet.GetSavedVersion方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: NewTest11
public void NewTest11()
{
Spreadsheet s = new Spreadsheet(x => true, x => x, "\"default\"");
s.SetContentsOfCell("a1", "Text");
s.Save("..\\..\\..\\Test.xml");
string sversion = s.GetSavedVersion("..\\..\\..\\Test.xml");
Assert.AreEqual("\"default\"", sversion);
}
示例2: TestSavedVersion3
public void TestSavedVersion3()
{
Spreadsheet sheet = new Spreadsheet();
sheet.GetSavedVersion("thisisnotafile.txt");
}
示例3: TestSavedVersion2
public void TestSavedVersion2()
{
string version = "10.2091.23";
Spreadsheet sheet = new Spreadsheet(x => true, s => s, version);
sheet.SetContentsOfCell("a1", "hello");
string path = "savedVersion2.xml";
sheet.Save(path);
Assert.AreEqual(version, sheet.GetSavedVersion(path));
}
示例4: TestSavedVersion1
public void TestSavedVersion1()
{
Spreadsheet sheet = new Spreadsheet();
sheet.SetContentsOfCell("a1", "hello");
string path = "savedVersion1.xml";
sheet.Save(path);
string version = "default";
Assert.AreEqual(version, sheet.GetSavedVersion(path));
}
示例5: GetSavedVersionTest
public void GetSavedVersionTest()
{
string existing_path = @"..\..\..\SpreadSheetTests\validspreadsheet.xml"; // the .. means up a directory
Spreadsheet target = new Spreadsheet(existing_path, s => true, s => s.ToUpper(), "dan1");
Assert.AreEqual("dan1", target.GetSavedVersion(existing_path));
}
示例6: GetSavedVersionTest
public void GetSavedVersionTest()
{
Spreadsheet target = new Spreadsheet(); // TODO: Initialize to an appropriate value
string filename = string.Empty; // TODO: Initialize to an appropriate value
string expected = string.Empty; // TODO: Initialize to an appropriate value
string actual;
actual = target.GetSavedVersion(filename);
Assert.AreEqual(expected, actual);
Assert.Inconclusive("Verify the correctness of this test method.");
}
示例7: GetSavedVersionTest
public void GetSavedVersionTest()
{
Spreadsheet s = new Spreadsheet(TestValidToFalse, TestNormalizeToUpperCase, "test123");
s.Save("test.xml");
Assert.AreEqual("test123", s.GetSavedVersion("test.xml"));
File.Delete("test.xml");
}
示例8: GetSavedVersionTest
public void GetSavedVersionTest()
{
// Returns the version information of the spreadsheet saved in the named file.
string filename = "GetSavedVersionTest.xml";
string version = "onesandcaps";
AbstractSpreadsheet s2 = new Spreadsheet(x => (Regex.IsMatch(x, @"^[a-zA-Z]+[1]$")) ? (true) : (false), y => y.ToUpper(), version);
s2.Save(filename);
AbstractSpreadsheet s = new Spreadsheet();
string actual = s.GetSavedVersion(filename);
string expected = version;
Assert.AreEqual(expected, actual);
}