From 9e492f19f96d230fd1fd028a230c6eea3f90e366 Mon Sep 17 00:00:00 2001 From: Benjamin Russell Date: Fri, 9 Sep 2016 15:02:45 -0700 Subject: [PATCH] Fixing broken OSX unit test caused by inability to hide files on unix (#41) --- .../QueryExecution/DataStorage/FileStreamWrapper.cs | 4 ---- .../QueryExecution/DataStorage/FileStreamWrapperTests.cs | 3 --- 2 files changed, 7 deletions(-) diff --git a/src/Microsoft.SqlTools.ServiceLayer/QueryExecution/DataStorage/FileStreamWrapper.cs b/src/Microsoft.SqlTools.ServiceLayer/QueryExecution/DataStorage/FileStreamWrapper.cs index afe616f3..3a6c3ecf 100644 --- a/src/Microsoft.SqlTools.ServiceLayer/QueryExecution/DataStorage/FileStreamWrapper.cs +++ b/src/Microsoft.SqlTools.ServiceLayer/QueryExecution/DataStorage/FileStreamWrapper.cs @@ -70,10 +70,6 @@ namespace Microsoft.SqlTools.ServiceLayer.QueryExecution.DataStorage // Open the requested file for reading/writing, creating one if it doesn't exist fileStream = new FileStream(fileName, FileMode.OpenOrCreate, accessMethod, FileShare.ReadWrite, bufferLength, false /*don't use asyncio*/); - - // make file hidden - FileInfo fileInfo = new FileInfo(fileName); - fileInfo.Attributes |= FileAttributes.Hidden; } /// diff --git a/test/Microsoft.SqlTools.ServiceLayer.Test/QueryExecution/DataStorage/FileStreamWrapperTests.cs b/test/Microsoft.SqlTools.ServiceLayer.Test/QueryExecution/DataStorage/FileStreamWrapperTests.cs index f1a4cda0..5911c577 100644 --- a/test/Microsoft.SqlTools.ServiceLayer.Test/QueryExecution/DataStorage/FileStreamWrapperTests.cs +++ b/test/Microsoft.SqlTools.ServiceLayer.Test/QueryExecution/DataStorage/FileStreamWrapperTests.cs @@ -76,9 +76,6 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.QueryExecution.DataStorage // ... The file should exist FileInfo fileInfo = new FileInfo(fileName); Assert.True(fileInfo.Exists); - - // ... The file should be marked as hidden - Assert.True((fileInfo.Attributes & FileAttributes.Hidden) != 0); } } finally