Skip to content

Commit

Permalink
Made all internal doc URL's relative and with a trailing slash
Browse files Browse the repository at this point in the history
  • Loading branch information
sunesimonsen committed Jan 3, 2019
1 parent 93d606f commit 16a3378
Show file tree
Hide file tree
Showing 22 changed files with 30 additions and 30 deletions.
2 changes: 1 addition & 1 deletion documentation/api/fail.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,5 +99,5 @@ If you are using the default error mode, you don't have to specify the
error message as it is just thrown away.

The diff is a method that will create a custom diff lazily. To get a
better understanding of the diff method see the [type](/api/addType)
better understanding of the diff method see the [type](../addType/)
documentation.
4 changes: 2 additions & 2 deletions documentation/api/promise-all.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ fulfilled. If any of the promises is rejected, the resulting promise will be
rejected with the same error.

This method is usually used in combination with
[expect.promise.settle](/api/promise-settle).
[expect.promise.settle](../promise-settle/).

Let's make an asynchronous assertion that we can use for the examples:

Expand All @@ -30,7 +30,7 @@ expect.addAssertion('to be a number after a short delay', function(
});
```

See the [promise](/api/promise) documentation for more details on how
See the [promise](../promise/) documentation for more details on how
expect.promise works.

The following code snippet creates a promise that is fulfilled when all the
Expand Down
2 changes: 1 addition & 1 deletion documentation/api/promise-any.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ expect.addAssertion('to be a number after a short delay', function(
});
```

See the [promise](/api/promise) documentation for more details on how
See the [promise](../promise/) documentation for more details on how
expect.promise works.

The following code snippet creates a promise that will be fulfilled when any
Expand Down
2 changes: 1 addition & 1 deletion documentation/api/promise-settle.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ expect.addAssertion('to be a number after a short delay', function(
});
```

See the [promise](/api/promise) documentation for more details on how
See the [promise](../promise/) documentation for more details on how
expect.promise works.

The following code snippet creates a promise that is rejected when any
Expand Down
2 changes: 1 addition & 1 deletion documentation/api/promise.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# expect.promise(promiseBody)

This method is used inside [addAssertion](/api/addAssertion) to create
This method is used inside [addAssertion](../addAssertion/) to create
a promise from the given body function.

Signature:
Expand Down
4 changes: 2 additions & 2 deletions documentation/api/use.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ to extend the instance.
expect.use(require('unexpected-sinon'));
```

Notice that it is usually a good idea to [clone](../clone) the instance before
Notice that it is usually a good idea to [clone](../clone/) the instance before
extending it with plugins.

## Example
Expand Down Expand Up @@ -101,4 +101,4 @@ expected [7,13] to contain 27
```

For more inspiration you can look at the source for existing plugins.
See [the plugin page](/plugins/) for a list.
See [the plugin page](../../plugins/) for a list.
2 changes: 1 addition & 1 deletion documentation/api/withError.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ In some situations you want to modify an error thrown from
unexpected. This method handles all the details for you.

Notice that this method is only available inside
[expect.addAssertion](/api/addAssertion).
[expect.addAssertion](../addAssertion/).

The standard case is to attach a diff or change the error message of
an error being thrown.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ return expect(
```

The expected value will be matched against the value with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`:

```js#async:true
Expand Down Expand Up @@ -50,7 +50,7 @@ expected Promise to be fulfilled with value satisfying 'def'
```

You can use the `exhaustively` flag to use strict
[to satisfy](/assertions/any/to-satisfy/) semantics:
[to satisfy](../../any/to-satisfy/) semantics:

```js#async:true
return expect(
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/Promise/to-be-fulfilled-with.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ return expect(
```

The expected value will be matched against the value with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`:

```js#async:true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ return expect(
```

The expected reason will be matched against the rejection reason with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`:

```js#async:true
Expand Down Expand Up @@ -70,7 +70,7 @@ expected Promise to be rejected with error satisfying Error('bugger')
```

You can use the `exhaustively` flag to use strict
[to satisfy](/assertions/any/to-satisfy/) semantics:
[to satisfy](../../any/to-satisfy/) semantics:

```js#async:true
var error = new Error('Oh dear');
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/Promise/to-be-rejected-with.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ return expect(
```

The expected reason will be matched against the rejection reason with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`:

```js#async:true
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/any/to-be-a.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This assertion makes use of the type system in Unexpected. That means
you can assert that a value is an instance of a type specified by
its name (as a string).

For more information abort the type system see: [Types](/api/addType/)
For more information abort the type system see: [Types](../../../api/addType/)

```js
expect(true, 'to be a', 'boolean');
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/any/to-be-ok.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Asserts that the value is _truthy_.

Alias for [to be truthy](../to-be-truthy).
Alias for [to be truthy](../../any/to-be-truthy/).

```js
expect(1, 'to be ok');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ when passed as parameter to function increment(n) { return n + 1; } to equal 3
```

This assertion delegates to the
[when passed as parameters to](/assertions/array-like/when-passed-as-parameters-to/)
[when passed as parameters to](../../array-like/when-passed-as-parameters-to/)
assertion and also supports the `async` and `constructor` flags.

If you don't provide an assertion to delegate to, the return value will be provided
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ expect(
```

The expected value will be matched against the value with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`. To use strict `to satisfy` semantics, you can
use the "exhaustively" flag:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ return expect(
```

A regular expression, Error instance, or an object will also work, as the
matching uses [to satisfy](/assertions/any/to-satisfy/) semantics:
matching uses [to satisfy](../../any/to-satisfy/) semantics:

```js#async:true
return expect(
Expand Down
4 changes: 2 additions & 2 deletions documentation/assertions/function/to-call-the-callback.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ ugh

The assertion will pass even if the function passes an error to the callback.
If you want that case to fail, look into the
[to call the callback without error](/assertions/function/to-call-the-callback-without-error/)
[to call the callback without error](../to-call-the-callback-without-error/)
assertion.

If you want the parameters passed to the callback to be the subject of further assertions,
you might be able to use the
[when passed as parameters to](/assertions/array-like/when-passed-as-parameters-to/) assertion.
[when passed as parameters to](../../array-like/when-passed-as-parameters-to/) assertion.

The parameters passed to the callback are also provided as the value of the returned promise,
so you can do further assertions like this:
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/function/when-called-with.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ return expect(add, 'called with', [1, 2]).then(function (result) {
});
```

When this assertion in used together with [to satisfy](/assertions/any/to-satisfy)
When this assertion in used together with [to satisfy](../../any/to-satisfy/)
we make sure that `this` is bound correctly:

```js
Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/function/when-called.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ return expect(giveMeFive, 'called').then(function (result) {
});
```

When this assertion in used together with [to satisfy](/assertions/any/to-satisfy)
When this assertion in used together with [to satisfy](../../any/to-satisfy/)
we make sure that `this` is bound correctly:

```js
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ expect(
```

The expected value will be matched against the value with
[to satisfy](/assertions/any/to-satisfy/) semantics, so you can pass any of the
[to satisfy](../../any/to-satisfy/) semantics, so you can pass any of the
values supported by `to satisfy`. To use strict `to satisfy` semantics, you can
use the "exhaustively" flag:

Expand Down
2 changes: 1 addition & 1 deletion documentation/assertions/object/to-have-key.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Asserts the presence of a key.

Alias for [to be have keys](../to-have-keys).
Alias for [to be have keys](../to-have-keys/).

```js
expect({ a: 'a', b: 'b', c: 'c' }, 'to have key', 'a');
Expand Down
8 changes: 4 additions & 4 deletions documentation/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ to satisfy { name: 'Unexpected', created: 2013 }
* Helps if you misspell assertions
* Compatible with all test frameworks
* Node.JS ready (`require('unexpected')`)
* Supports [asynchronous assertions using promises](/api/addAssertion/#asynchronous-assertions)
* Supports [asynchronous assertions using promises](./api/addAssertion/#asynchronous-assertions)
* Single global with no prototype extensions or shims
* Cross-browser: works on Chrome, Firefox, Safari, Opera, IE11, Edge

Expand Down Expand Up @@ -190,7 +190,7 @@ See [changelog](https://github.com/unexpectedjs/unexpected/blob/master/CHANGELOG
### 8.0.0

* All errors originating from assertions are now instances of
[`UnexpectedError`](/api/UnexpectedError/), which can be manipulated before being
[`UnexpectedError`](./api/UnexpectedError/), which can be manipulated before being
serialized.
* Error messages and diffs are now built lazily, improving
performance.
Expand All @@ -209,13 +209,13 @@ See [changelog](https://github.com/unexpectedjs/unexpected/blob/master/CHANGELOG
multiple lines and is identical to the parent subject.
* Added a new `bubbleThrough` error mode that will make the error
bubble all the way to the top, mainly useful internally.
* Added [`to error`](/assertions/function/to-error/) assertion.
* Added [`to error`](./assertions/function/to-error/) assertion.
* Minor bugfixes and output tweaks.

### 7.0.0

* Support for
[asynchronous assertions using promises](/api/addAssertion/#asynchronous-assertions).
[asynchronous assertions using promises](./api/addAssertion/#asynchronous-assertions).
All built-in assertions that delegate to other assertions (such as `to satisfy`)
have been rewritten to support this. The change is fully backwards compatible.
* Removed support for the `to be an array of` and
Expand Down

0 comments on commit 16a3378

Please sign in to comment.