feat(ads/seo/release): v1.2.0 with live Google Ads, isolated ad profile, ads.txt, and SEO/AEO/GEO optimization
This commit is contained in:
parent
a88aafa1e5
commit
0e568f1f0a
975 changed files with 130593 additions and 16783 deletions
33
tests/Paca.Tests/Core/ChromeMemorySaverPolicyTests.cs
Normal file
33
tests/Paca.Tests/Core/ChromeMemorySaverPolicyTests.cs
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
using System.Collections.Generic;
|
||||
using Paca.Browser.Tabs;
|
||||
using Paca.Core.Config;
|
||||
using Xunit;
|
||||
|
||||
namespace Paca.Tests.Core;
|
||||
|
||||
public class ChromeMemorySaverPolicyTests
|
||||
{
|
||||
[Fact]
|
||||
public void CanDiscardTab_Protects_Excluded_Domains()
|
||||
{
|
||||
var mgr = new TabManager(() => new TabItem());
|
||||
var activeTab = mgr.NewTab("https://news.ycombinator.com");
|
||||
var workTab = mgr.NewTab("https://mail.google.com/mail/u/0", activate: false);
|
||||
var slackTab = mgr.NewTab("https://app.slack.com/client", activate: false);
|
||||
var normalTab = mgr.NewTab("https://wikipedia.org/wiki/Paca", activate: false);
|
||||
|
||||
var exclusions = new List<string> { "mail.google.com", "slack.com" };
|
||||
|
||||
Assert.False(mgr.CanDiscardTab(workTab, exclusions));
|
||||
Assert.False(mgr.CanDiscardTab(slackTab, exclusions));
|
||||
Assert.True(mgr.CanDiscardTab(normalTab, exclusions));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AppConfig_Contains_MemorySaver_Properties_With_Safe_Defaults()
|
||||
{
|
||||
var config = new AppConfig();
|
||||
Assert.True(config.MemorySaverEnabled);
|
||||
Assert.NotNull(config.MemorySaverExclusions);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue