Cleaned and fixed broken tests

This commit is contained in:
Mark McDowall 2012-10-19 18:42:42 -07:00
commit f9370a8aec
4 changed files with 41 additions and 93 deletions

View file

@ -77,9 +77,11 @@ namespace NzbDrone.Common
public virtual long GetSize(string path)
{
if (!FileExists(path))
throw new FileNotFoundException("File doesn't exist: " + path);
var fi = new FileInfo(path);
return fi.Length;
//return new FileInfo(path).Length;
}
public virtual String CreateDirectory(string path)
@ -218,14 +220,6 @@ namespace NzbDrone.Common
return String.Equals(firstPath.NormalizePath(), secondPath.NormalizePath(), StringComparison.InvariantCultureIgnoreCase);
}
public virtual long GetFileSize(string path)
{
if (!FileExists(path))
throw new FileNotFoundException("File doesn't exist: " + path);
return new FileInfo(path).Length;
}
public virtual void FileSetLastWriteTimeUtc(string path, DateTime dateTime)
{
File.SetLastWriteTimeUtc(path, dateTime);