We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HttpContextMoq/src/HttpContextMoq/SessionFake.cs
Line 27 in c517b94
The dotnet Session when you set again it will just updates the existing dictionary entry
Example: HttpContext.Session.SetString("TestMe", "TestValue"); HttpContext.Session.SetString("TestMe", "TestValue1");
Value in session with key just gets updated
I created my own session fake and here is the fix if you want to incorporate into the sessionfake here
public void Set(string key, byte[] value) { if(this.data.ContainsKey(key)) { this.data[key] = value; } else { this.data.Add(key, value); } }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
HttpContextMoq/src/HttpContextMoq/SessionFake.cs
Line 27 in c517b94
The dotnet Session when you set again it will just updates the existing dictionary entry
Example:
HttpContext.Session.SetString("TestMe", "TestValue");
HttpContext.Session.SetString("TestMe", "TestValue1");
Value in session with key just gets updated
I created my own session fake and here is the fix if you want to incorporate into the sessionfake here
public void Set(string key, byte[] value)
{
if(this.data.ContainsKey(key))
{
this.data[key] = value;
}
else
{
this.data.Add(key, value);
}
}
The text was updated successfully, but these errors were encountered: