Skip to content

Commit f46137b

Browse files
authored
Merge pull request #86 from chkware/feat/add-site
Feat: Add basic home site and a home page
2 parents c41aa14 + b6ef999 commit f46137b

31 files changed

Lines changed: 580 additions & 52 deletions

.eslintrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,6 @@ module.exports = {
2525
plugins: ["react"],
2626
rules: {
2727
"react/react-in-jsx-scope": "off",
28+
"react/prop-types": "off",
2829
},
2930
};

docs/examples/http-examples.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,14 @@ title: Http examples
66

77
- This page should be use as reference for specification files.
88
- This page is subject to change. It is requested to check this page frequently.
9+
910
:::
1011

1112
:::note
1213
Case-wise more example can be found in [https://github.com/chkware/cli](https://github.com/chkware/cli/tree/main/tests/resources/storage/sample_config) repository
1314
:::
1415

15-
[Http specification document reference](/references/http-reference)
16+
[Http specification document reference](/docs/references/http-reference)
1617

1718
Following examples are using HTTP _GET_ and _POST_ method. Although all these example are still valid for _POST_, _PUT_, _PATCH_, _DELETE_, _OPTIONS_, _HEAD_ method as well. You can still send a request body with _GET_ or _HEAD_ method for the sake of testing API.
1819

docs/examples/testcase-examples.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Case-wise more example can be found in [https://github.com/chkware/cli](https://
1515

1616
:::
1717

18-
[Testcase specification document reference](/references/testcase-reference)
18+
[Testcase specification document reference](/docs/references/testcase-reference)
1919

2020
### A minimal Testcase with in-file request
2121

@@ -45,7 +45,7 @@ On the `asserts`, we are asserting that
4545
- The response code is 201, or the resource was created
4646
- The response if a map / dictionary
4747

48-
Assertion [reference with examples](/references/testcase-reference#assertions) can be found here.
48+
Assertion [reference with examples](/docs/references/testcase-reference#assertions) can be found here.
4949

5050
### A minimal Testcase with out-file request
5151

@@ -118,4 +118,4 @@ spec:
118118

119119
Please notice that if we do not set a `with` then request will be sent with default value.
120120

121-
Assertion [reference with examples](/references/testcase-reference#assertions) can be found here.
121+
Assertion [reference with examples](/docs/references/testcase-reference#assertions) can be found here.

docs/examples/variable-examples.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Case-wise more example can be found in [https://github.com/chkware/cli](https://
1515

1616
:::
1717

18-
[Variable specification document reference](/references/variable-reference)
18+
[Variable specification document reference](/docs/references/variable-reference)
1919

2020
We can also use variables inside a http and testcase specification file. See examples below.
2121

docs/home.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ API quality test, and automation management is not easy to develop, and maintain
1616

1717
**_CHKware_** (pronounced as _/tʃek-wer/_, i.e. _check-ware_) is a low-code API quality testing, and automation toolbox. It helps you write accurate, robust, and expressive feature tests for your API in less time than usual.
1818

19-
Read [about the problems](/introduction) _CHKware_ addresses. Find [changelog](https://github.com/chkware/cli/blob/main/docs/CHANGELOG.md).
19+
Read [about the problems](/docs/introduction) _CHKware_ addresses. Find [changelog](https://github.com/chkware/cli/blob/main/docs/CHANGELOG.md).
2020

2121
### Setup
2222

@@ -26,11 +26,11 @@ With [**Python 3.11**](https://www.python.org/downloads/) and [**Pipx**](https:/
2626
pipx install chk
2727
```
2828

29-
Jump to the [setup guide](/setup) for different ways to install **_CHKware_**.
29+
Jump to the [setup guide](/docs/setup) for different ways to install **_CHKware_**.
3030

3131
### Usage
3232

33-
[Get started](/quick-start) quickly here.
33+
[Get started](/docs/quick-start) quickly here.
3434

3535
### Ask anything
3636

docs/quick-start.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ title: Quick Start
44

55
:::note
66

7-
- **Prerequisite**: First, [setup **CHKware**](/setup) to continue
8-
- Find [More `http` examples](/examples/http-examples) here
7+
- **Prerequisite**: First, [setup **CHKware**](/docs/setup) to continue
8+
- Find [More `http` examples](/docs/examples/http-examples) here
99

1010
:::
1111

@@ -56,13 +56,13 @@ Let's call an API that returns current bitcoin price in USD, and test it. Please
5656

5757
### Explanation
5858

59-
We call this `bitcoin-usd-testcase.chk` a spec or specification file. The content that you put was a [testcase specification](/references/testcase-reference).
59+
We call this `bitcoin-usd-testcase.chk` a spec or specification file. The content that you put was a [testcase specification](/docs/references/testcase-reference).
6060

6161
Let us look into the content and see what we wrote.
6262

6363
On 1st line we wrote document version with `version:` same as we do on other config files i.e. terraform, ansible, etc. This is not all too important now.
6464

65-
On 2nd line, we wrote a `request:` block, which define how to sent the request to server. More on this block on [http specification](/references/http-reference).
65+
On 2nd line, we wrote a `request:` block, which define how to sent the request to server. More on this block on [http specification](/docs/references/http-reference).
6666

6767
Then we wrote a `asserts:` sub-section under `spec:` block which defines how to check the response those we received.
6868

docs/references/assertion-reference.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ title: Assertion reference
1010

1111
:::
1212

13-
Assertions are integral part of [Testcase spec.](/references/testcase-reference) Following are the assertion keys supported in most latest version of Testcase spec.
13+
Assertions are integral part of [Testcase spec.](/docs/references/testcase-reference) Following are the assertion keys supported in most latest version of Testcase spec.
1414

1515
Assertions are used to validate data in testcase specification after http request execution has successfully returned the response.
1616

docs/references/concepts.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ There are two parts to **`CHKware`** tool.
1515

1616
This sub command runs a file written in [http specification file](http-reference) format.
1717

18-
After you execute this command `chk` should make request by given request format, and display the response. You can also customize the response with `expose` key. see [usage](/examples/http-examples#request-with-form) and [documentation](/references/http-reference).
18+
After you execute this command `chk` should make request by given request format, and display the response. You can also customize the response with `expose` key. see [usage](/docs/examples/http-examples#request-with-form) and [documentation](/docs/references/http-reference).
1919

2020
#### Options
2121

@@ -33,7 +33,7 @@ There are two parts to **`CHKware`** tool.
3333

3434
This sub command runs a file written in [testcase specification file](testcase-reference) format.
3535

36-
After you execute this command `chk` should re-use `http` utility to request as per given structure on the file, execute test assertions, and display the result of the assertions. See [example](/examples/testcase-examples).
36+
After you execute this command `chk` should re-use `http` utility to request as per given structure on the file, execute test assertions, and display the result of the assertions. See [example](/docs/examples/testcase-examples).
3737

3838
#### Options
3939

docs/references/http-reference.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The **Http specification format** is how anyone express a Http request. Followin
1313

1414
Http specification document is a _**versioned document**_, meaning there MUST be a `version:` key on the document.
1515

16-
It's also an _**exposable document**_ meaning you can expose local data using `expose:` key in the document. More on this in [variable spec. reference](/references/variable-reference)
16+
It's also an _**exposable document**_ meaning you can expose local data using `expose:` key in the document. More on this in [variable spec. reference](/docs/references/variable-reference)
1717

1818
### All supported nodes in http specification document
1919

@@ -120,13 +120,13 @@ expose:
120120
121121
### `version` (<small>_`required`_</small>)
122122

123-
`version` is a top-level block that defines a document version. How to write a `version:` block is already defined in [_version reference_](/references/version-reference).
123+
`version` is a top-level block that defines a document version. How to write a `version:` block is already defined in [_version reference_](/docs/references/version-reference).
124124

125125
### `variables`
126126

127-
`variables` is a top-level block that defines local variables. These variables are file scoped. How to write a `variables:` block is already defined in [_variable-reference_](/references/variable-reference).
127+
`variables` is a top-level block that defines local variables. These variables are file scoped. How to write a `variables:` block is already defined in [_variable-reference_](/docs/references/variable-reference).
128128

129-
One special local variable named `_response` get added after the response received successfully. This local variable is accessible under [_exposable block_](/references/variable-reference#exposable).
129+
One special local variable named `_response` get added after the response received successfully. This local variable is accessible under [_exposable block_](/docs/references/variable-reference#exposable).
130130

131131
### `request` (<small>_`required`_</small>)
132132

@@ -304,4 +304,4 @@ request:
304304

305305
For http specification document local variable called `_response` which holds successful response, is available.
306306

307-
See docs on [expose node](/references/variable-reference#expose-node)
307+
See docs on [expose node](/docs/references/variable-reference#expose-node)

docs/references/testcase-reference.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The _Testcase specification_ format is how anyone express one or more test case(
1616

1717
Testcase specification document is a versioned document, meaning there MUST be a `version:` key on the document.
1818

19-
It's also an _**exposable document**_ meaning you can expose local data using `expose:` key in the document. More on this in [variable spec. reference](/references/variable-reference)
19+
It's also an _**exposable document**_ meaning you can expose local data using `expose:` key in the document. More on this in [variable spec. reference](/docs/references/variable-reference)
2020

2121
### Reference as example
2222

@@ -60,7 +60,7 @@ expose:
6060
- "{$_response}"
6161
```
6262
63-
#### 2. `request` in separate http spec. doc.
63+
#### 2. `request` in separate http spec. doc
6464

6565
```yaml
6666
# file: some-request.chk
@@ -103,20 +103,20 @@ expose: ~
103103

104104
### `version` (<small>_`required`_</small>)
105105

106-
`version` is a top-level block that defines a document version. How to write a `version:` block, is [already defined here](/references/version-reference).
106+
`version` is a top-level block that defines a document version. How to write a `version:` block, is [already defined here](/docs/references/version-reference).
107107

108108
### `request`
109109

110110
- _`required`_ if no external http spec. doc to be linked
111111
- _`must not`_ if `spec.execute.file` if a http specification doc is linked
112112

113-
`request` is a top-level block that defines a http request. How to write a `request:` block, is [already defined here](/references/http-reference#request-required).
113+
`request` is a top-level block that defines a http request. How to write a `request:` block, is [already defined here](/docs/references/http-reference#request-required).
114114

115115
`request` block, and `spec.execute.file` MUST NOT stay on same file. System will throw an error on that case.
116116

117117
### `variables`
118118

119-
`variables` is a top-level block that defines local variables. These variables are file scoped. How to write a `variables:` block, is [already defined here](/references/variable-reference).
119+
`variables` is a top-level block that defines local variables. These variables are file scoped. How to write a `variables:` block, is [already defined here](/docs/references/variable-reference).
120120

121121
### `spec` (<small>_`required`_</small>)
122122

@@ -169,12 +169,12 @@ spec:
169169
actual: "{$Response}"
170170
```
171171

172-
[More about assertions](/references/assertion-reference) can be found here.
172+
[More about assertions](/docs/references/assertion-reference) can be found here.
173173

174174
### `expose`
175175

176176
`expose` is a sub-block, that can be used to expose local variable of this file to outer scope.
177177

178178
For testcase specification document local variable called `_assertion_results` which holds after assertion output, and `_response` which holds response after request execute, are available.
179179

180-
See docs on [expose node](/references/variable-reference#expose-node)
180+
See docs on [expose node](/docs/references/variable-reference#expose-node)

0 commit comments

Comments
 (0)