A library that makes it possible to compare two AngleSharp node lists and get a list of differences between them.
Перейти к файлу
Sebastian Stehle 370d44b6a6
feat: changed CompareStrategy to return CompareResult
* Ensure that the correct diff is returned.

* Use records.

* Move kind to beginning of text.

* Fix compilation error and test for custom diff.

* Update src/AngleSharp.Diffing/Core/CompareResult.cs

Co-authored-by: Egil Hansen <egil@assimilated.dk>

* Update src/AngleSharp.Diffing/Core/Comparison.cs

Co-authored-by: Egil Hansen <egil@assimilated.dk>

* Update src/AngleSharp.Diffing/Core/AttributeComparison.cs

Co-authored-by: Egil Hansen <egil@assimilated.dk>

* 1. Rename CompareResultDecision
2. Move method inside type.

* Rename method.

* Get rid of StylesOrder

* More records.

* refactor: move IsExternalInit to folder matching namespace

* add comment to explain use of ReferenceEquals

* Move types into two files

* simplify attrdiff object hierarchi

* remove diff type check

* clean up using statements

* refactor: IsSameOrSkip as property

* refactor: normalize tests

* feat: add CommentComparer tests

* nodes do not have different closing tags, elements do, so switch to using ElementDiff when comparing elements

* fix: override ComparisonSource.ToString for better output

* fix: use unspecified when no diff is returned

* override ToString in AttributeComparisonSource

* bump version number

---------

Co-authored-by: Egil Hansen <egil@assimilated.dk>
2023-03-28 22:29:49 +00:00
.github Merge branch 'master' into devel 2021-04-28 09:33:46 +00:00
src feat: changed CompareStrategy to return CompareResult 2023-03-28 22:29:49 +00:00
tools build: update cake addin Cake.FileHelpers to v4.0.1 2022-03-14 12:26:41 +00:00
.gitattributes Moved files / folder structure 2019-10-31 22:23:01 +01:00
.gitignore Ignore tools 2019-10-31 22:23:18 +01:00
CHANGELOG.md feat: changed CompareStrategy to return CompareResult 2023-03-28 22:29:49 +00:00
LICENSE Merge branch 'master' of https://github.com/AngleSharp/AngleSharp.GitBase into devel 2021-04-22 11:47:16 +02:00
README.md Merge branch 'master' into dev 2019-12-26 08:51:22 +00:00
build.cake Build process set up 2019-10-31 22:23:26 +01:00
build.ps1 Use GH actions 2021-04-21 23:58:20 +02:00
build.sh Adjusted with review comments 2021-04-22 09:57:03 +02:00
header.png Moved header and logo files 2019-12-26 08:50:34 +00:00
logo.png Moved header and logo files 2019-12-26 08:50:34 +00:00

README.md

AngleSharp Diffing - A diff/compare library for AngleSharp

Build status GitHub Tag NuGet Count Issues Open Gitter Chat CLA Assistant

AngleSharp Diffing makes it possible to compare AngleSharp control nodes and test nodes and get a list of differences between them.

The control nodes represents the expected HTML tree, i.e. how the nodes are expected to look, and the test nodes represents the nodes that should be compared to the control nodes.

Documentation:

Acknowledgments

  • Florian Rappl from the AngleSharp team for providing ideas, input and sample code for working with AngleSharp.
  • XMLUnit has been a great inspiration for creating this library.