Skip to content

Commit

Permalink
Added test for new API
Browse files Browse the repository at this point in the history
  • Loading branch information
FlorianRappl committed Jan 19, 2024
1 parent 8205cf8 commit caab82a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/AngleSharp.Css.Tests/Extensions/AnalysisWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,18 @@ public void GetCascadedValueOfTextTransformFromElementStyle()
Assert.AreEqual("uppercase", styleNormal.GetTextTransform());
}

[Test]
public void GetCascadedValueOfTextTransformFromElementStyleWithElementApi()
{
var sourceCode = "<!doctype html><div style=\"text-transform: uppercase\"><p><span>Bold text";

var document = ParseDocument(sourceCode);
var element = document.QuerySelector("span");
var styleNormal = element.ComputeStyle();
Assert.IsNotNull(styleNormal);
Assert.AreEqual("uppercase", styleNormal.GetTextTransform());
}

[Test]
public async Task NullSelectorStillWorks_Issue52()
{
Expand Down

0 comments on commit caab82a

Please sign in to comment.