History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: WET-225
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Sowmyashree
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
WET

The Save() method of TestDefinition class throws a System.UnauthorizedAccessException when called with no parameters .

Created: 11/Sep/06 06:10 AM   Updated: 18/Jun/07 10:24 AM
Component/s: None
Affects Version/s: 0.9.8_beta1
Fix Version/s: Future

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown


 Description  « Hide
The TestDefinition.Save() method throws System.UnauthorizedAccessException when attempting to save the TestDefinition to location prespecified by
 "futuresave " attribute of TestDefinition.Import(string filename, String futureSave) method

The filename is tripped off from the complete path specified in futuresave and only the "directory part " of the path is retained . Thus the problem is caused ..
 
Stack Trace ::

Script_assistant.test.TestDefinitionTest.SaveWithFutureAttribSet : System.UnauthorizedAccessException : Access to the path 'D:\workarea\wet\main\internal\testcases\testdata\td_with_new_trans_pre_tear' is denied..

at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options)
   at System.IO.StreamWriter.CreateFile(String path, Boolean append)
   at System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize)
   at System.IO.StreamWriter..ctor(String path)
   at Script_assistant.TestDefinition.Save(String path) in D:\workarea\wet\main\openqa\src\TestDefinition.cs:line 544
   at Script_assistant.TestDefinition.Save() in D:\workarea\wet\main\openqa\src\TestDefinition.cs:line 552
   at Script_assistant.test.TestDefinitionTest.SaveWithFutureAttribSet() in D:\workarea\wet\main\internal\advancedunittests\tests\TestDefinitionTest.cs:line 719




 All   Comments   Work Log   Change History      Sort Order:
Raghu Venkataramana - 16/Sep/06 01:33 AM
Although this is an important one, we shouldn't try to fix this before 0.9.8 beta2 release - the method apparently is not being used or the problem is being worked around in the place where being called. If the latter is true, then we might be breaking the 'save' functionality of the WET UI.

Raghu Venkataramana - 23/Mar/07 03:33 AM
This one is not causing any problem in real usage.