public void CanParseFileNameWithCommaPlusVersionString()
        {
            string text = entryPathWithComma + RecentFileEntry.Separator + entryVersion.ToString();

            entry = RecentFileEntry.Parse(text);
            Assert.AreEqual(entryPathWithComma, entry.Path);
            Assert.AreEqual(entryVersion, entry.CLRVersion);
        }
Exemplo n.º 2
0
        private void AddEntriesForPrefix(string prefix)
        {
            for (int index = 1; index < MaxFiles; index++)
            {
                if (fileEntries.Count >= MaxFiles)
                {
                    break;
                }

                string fileSpec = ServiceContext.UserSettings.GetSetting(GetRecentFileKey(prefix, index)) as string;
                if (fileSpec != null)
                {
                    fileEntries.Add(RecentFileEntry.Parse(fileSpec));
                }
            }
        }
 public void CanParseSimpleFileNameWithComma()
 {
     entry = RecentFileEntry.Parse(entryPathWithComma);
     Assert.AreEqual(entryPathWithComma, entry.Path);
     Assert.AreEqual(currentVersion, entry.CLRVersion);
 }