Skip to content

Commit

Permalink
Release 0.5.4
Browse files Browse the repository at this point in the history
  • Loading branch information
ghostbuster91 committed Jul 25, 2021
1 parent b9027e4 commit 3570798
Show file tree
Hide file tree
Showing 9 changed files with 42 additions and 23 deletions.
12 changes: 9 additions & 3 deletions generated-docs/out/integrations/cats.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ This module contains integration layer between [org.typelevel.cats](https://gith
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-cats" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-cats" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-cats::0.5.3"
ivy"com.softwaremill.diffx::diffx-cats::0.5.4"
```

## Usage
Expand Down Expand Up @@ -39,7 +39,13 @@ compare(t1, t2)
// "ints" -> DiffResultObject(
// name = "List",
// fields = ListMap(
// "0" -> DiffResultString(diffs = List(DiffResultValue(left = "a", right = "b")))
// "0" -> DiffResultString(
// diffs = List(
// DiffResultStringLine(
// diffs = List(DiffResultValue(left = "a", right = "b"))
// )
// )
// )
// )
// )
// )
Expand Down
10 changes: 7 additions & 3 deletions generated-docs/out/integrations/refined.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ This module contains integration layer between [eu.timepit.refined](https://gith
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-refined" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-refined" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-refined::0.5.3"
ivy"com.softwaremill.diffx::diffx-refined::0.5.4"
```

## Usage
Expand Down Expand Up @@ -42,7 +42,11 @@ compare(t1, t2)
// fields = ListMap(
// "posInt" -> IdenticalValue(value = 1),
// "nonEmptyString" -> DiffResultString(
// diffs = List(DiffResultValue(left = "foo", right = "bar"))
// diffs = List(
// DiffResultStringLine(
// diffs = List(DiffResultValue(left = "foo", right = "bar"))
// )
// )
// )
// )
// )
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/out/integrations/tagging.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ This module contains integration layer between [com.softwaremill.common.tagging]
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-tagging" % "0.5.3"
"com.softwaremill.diffx" %% "diffx-tagging" % "0.5.4"
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-tagging::0.5.3"
ivy"com.softwaremill.diffx::diffx-tagging::0.5.4"
```

## Usage
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/out/test-frameworks/munit.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ To use with munit, add following dependency:
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-munit" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-munit" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-munit::0.5.3"
ivy"com.softwaremill.diffx::diffx-munit::0.5.4"
```

## Usage
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/out/test-frameworks/scalatest.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ To use with scalatest, add the following dependency:
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-scalatest" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-scalatest" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-scalatest::0.5.3"
ivy"com.softwaremill.diffx::diffx-scalatest::0.5.4"
```

## Usage
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/out/test-frameworks/specs2.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ To use with specs2, add the following dependency:
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-specs2" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-specs2" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-specs2::0.5.3"
ivy"com.softwaremill.diffx::diffx-specs2::0.5.4"
```

## Usage
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/out/test-frameworks/utest.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ To use with utest, add following dependency:
## sbt

```scala
"com.softwaremill.diffx" %% "diffx-utest" % "0.5.3" % Test
"com.softwaremill.diffx" %% "diffx-utest" % "0.5.4" % Test
```

## mill

```scala
ivy"com.softwaremill.diffx::diffx-utest::0.5.3"
ivy"com.softwaremill.diffx::diffx-utest::0.5.4"
```

## Usage
Expand Down
15 changes: 9 additions & 6 deletions generated-docs/out/usage/output.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,16 @@ In <b>File | Settings | Editor | Color Scheme | Console Colors | Console | Error

## colors & signs

I found it confusing to use the terms `expected`/`actual` as there seems to be no golden rule whether to keep expected on the right side or on the left side.
Because of that, diffx refers to the values that are compared as `left` and `right` value.
Diffx refers to the values that are compared as `left` and `right`, but you can think of them as `actual` and `expected`.

By default, the difference is shown in the following form:

`leftColor(leftValue) -> rightColor(rightValue)`

which in terms of missing/additional values e.g. in collections looks as follows:
When comparing collection types the difference is calculated against the `right` value

`leftColor(additionalValue)` in case the value was present on the left-hand side and absent on the right side
`rightColor(missingValue)` in case the value was absent on the left-hand side and present on the right side
`rightColor(additionalValue)` when there is an additional entity on the left-hand side
`leftColor(missingValue)` when there is a missing entity on the left-hand side


Where, by default, `rightColor` is green and `leftColor` is red.
Expand Down Expand Up @@ -54,7 +53,11 @@ val result = compare(Person("Bob", 23), Person("Alice", 23))
// name = "Person",
// fields = ListMap(
// "name" -> DiffResultString(
// diffs = List(DiffResultValue(left = "Bob", right = "Alice"))
// diffs = List(
// DiffResultStringLine(
// diffs = List(DiffResultValue(left = "Bob", right = "Alice"))
// )
// )
// ),
// "age" -> IdenticalValue(value = 23)
// )
Expand Down
8 changes: 7 additions & 1 deletion generated-docs/out/usage/sequences.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,13 @@ val bob = Person("1","Bob")
compare(Map("1" -> bob), Map("2" -> bob))
// res3: DiffResult = DiffResultMap(
// entries = Map(
// DiffResultString(diffs = List(DiffResultValue(left = "1", right = "2"))) -> DiffResultObject(
// DiffResultString(
// diffs = List(
// DiffResultStringLine(
// diffs = List(DiffResultValue(left = "1", right = "2"))
// )
// )
// ) -> DiffResultObject(
// name = "Person",
// fields = ListMap(
// "id" -> IdenticalValue(value = "1"),
Expand Down

0 comments on commit 3570798

Please sign in to comment.