using Microsoft.AspNetCore.Http;

namespace eSuite.API.UnitTests.SingleSignOn.CookieManager;

public class FakeResponseCookies : IResponseCookies
{
    public Dictionary<string, FakeCookie> CookieDictionary { get; set; } = new();

    public void Append(string key, string value)
    {
        throw new NotImplementedException();
    }

    public void Append(string key, string value, CookieOptions options)
    {
        CookieDictionary.Add(key, new FakeCookie
        {
            Value = value,
            CookieOptions = options
        });
    }

    public void Delete(string key)
    {
        if (CookieDictionary.ContainsKey(key))
            CookieDictionary.Remove(key);
    }

    public void Delete(string key, CookieOptions options)
    {
        throw new NotImplementedException();
    }
}