Add callout plugin to replace alert html
Project: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/repo Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/commit/fe43f07b Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/tree/fe43f07b Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/diff/fe43f07b Branch: refs/heads/master Commit: fe43f07b572b3c23fac3d84123077961704227eb Parents: ccca78a Author: Thomas Bouron <[email protected]> Authored: Wed Oct 11 13:31:10 2017 +0100 Committer: Thomas Bouron <[email protected]> Committed: Mon Oct 16 14:56:04 2017 +0100 ---------------------------------------------------------------------- book.json | 3 +- guide/blueprints/test/test-entities.md | 46 +++++++++++------------ package-lock.json | 57 +++++++++++++++++++++++++++++ package.json | 1 + 4 files changed, 81 insertions(+), 26 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/brooklyn-docs/blob/fe43f07b/book.json ---------------------------------------------------------------------- diff --git a/book.json b/book.json index f11eae7..a515dd7 100644 --- a/book.json +++ b/book.json @@ -4,7 +4,8 @@ "plugins" : [ "include-highlight", "theme-api", - "collapsible-chapters" + "collapsible-chapters", + "bootstrap-callout" ], "pluginsConfig": { "include-highlight": { http://git-wip-us.apache.org/repos/asf/brooklyn-docs/blob/fe43f07b/guide/blueprints/test/test-entities.md ---------------------------------------------------------------------- diff --git a/guide/blueprints/test/test-entities.md b/guide/blueprints/test/test-entities.md index 4d3a849..2f72036 100644 --- a/guide/blueprints/test/test-entities.md +++ b/guide/blueprints/test/test-entities.md @@ -33,7 +33,7 @@ Timeouts on child entities should be set relative to the start of the `ParallelT ### LoopOverGroupMembersTestCase The `LoopOverGroupMembersTestCase` entity is configured with a target group and a test specification. For each member of the targeted group, the test case will create a TargetableTestComponent entity from the supplied test specification and set the components target to be the group member. -!CODEFILE "example_yaml/entities/loopovergroupmembers-entity.yaml' +!CODEFILE "example_yaml/entities/loopovergroupmembers-entity.yaml" #### Parameters - `target` - group who's members are to be tested, specified via DSL. For example, `$brooklyn:entity("tomcat")`. See also the `targetId` parameter. @@ -67,12 +67,11 @@ The `TestSensor` entity performs an assertion on a specified sensors value. - `timeout` - duration to wait on assertion to return a result. For example `10s`, `10m`, etc - `assert` - assertion to perform on the specified sensor value. See section on assertions below. -<div class="alert alert-info"> - <strong>Tip:</strong> If the <code>TestSensor</code> is wrapped within a <code>TestCase</code>, - <code>ParallelTestCase</code> or <code>LoopOverGroupMembersTestCase</code> that set the target, - <strong>you don't need to specify the target</strong>, unless you want to test a different entity. -</div> - +> #### info::Tip +> +> If the `TestSensor` is wrapped within a `TestCase`, + `ParallelTestCase` or `LoopOverGroupMembersTestCase` that set the target, + **you don't need to specify the target**, unless you want to test a different entity. ### TestEffector The `TestEffector` entity invokes the specified effector on a target entity. If the result of the effector is a String, it will then perform assertions on the result. @@ -87,12 +86,11 @@ The `TestEffector` entity invokes the specified effector on a target entity. If - `params` - parameters to pass to the effector, these will depend on the entity and effector being tested. The example above shows the `url` and `targetName` parameters being passed to Tomcats `deploy` effector. - `assert` - assertion to perform on the returned result. See section on assertions below. -<div class="alert alert-info"> - <strong>Tip:</strong> If the <code>TestEffector</code> is wrapped within a <code>TestCase</code>, - <code>ParallelTestCase</code> or <code>LoopOverGroupMembersTestCase</code> that set the target, - <strong>you don't need to specify the target</strong>, unless you want to test a different entity. -</div> - +> #### info::Tip +> +> If the `TestEffector` is wrapped within a `TestCase`, + `ParallelTestCase` or `LoopOverGroupMembersTestCase` that set the target, + **you don't need to specify the target**, unless you want to test a different entity. ### TestHttpCall The `TestHttpCall` entity performs a HTTP GET on the specified URL and performs an assertion on the response. @@ -105,12 +103,11 @@ The `TestHttpCall` entity performs a HTTP GET on the specified URL and performs - `applyAssertionTo` - The filed to apply the assertion to. For example `status`, `body` - `assert` - assertion to perform on the response. See section on assertions below. -<div class="alert alert-info"> - <strong>Tip:</strong> If the <code>TestHttpCall</code> is wrapped within a <code>TestCase</code>, - <code>ParallelTestCase</code> or <code>LoopOverGroupMembersTestCase</code> that set the target, - <strong>you don't need to specify the target</strong>, unless you want to test a different entity. -</div> - +> #### info::Tip +> +> If the `TestHttpCall` is wrapped within a `TestCase`, + `ParallelTestCase` or `LoopOverGroupMembersTestCase` that set the target, + **you don't need to specify the target**, unless you want to test a different entity. ### TestSshCommand The TestSshCommand runs a command on the host of the target entity. @@ -132,12 +129,11 @@ Either a bash command may be provided in the YAML, or a URL for a script which w - `assertOut` - Assertions on the standard output of the command as a String. - `assertErr` - Assertions on the standard error of the command as a String. -<div class="alert alert-info"> - <strong>Tip:</strong> If the <code>TestSshCommand</code> is wrapped within a <code>TestCase</code>, - <code>ParallelTestCase</code> or <code>LoopOverGroupMembersTestCase</code> that set the target, - <strong>you don't need to specify the target</strong>, unless you want to test a different entity. -</div> - +> #### info::Tip +> +> If the `TestSshCommand` is wrapped within a `TestCase`, + `ParallelTestCase` or `LoopOverGroupMembersTestCase` that set the target, + **you don't need to specify the target**, unless you want to test a different entity. ## Assertions http://git-wip-us.apache.org/repos/asf/brooklyn-docs/blob/fe43f07b/package-lock.json ---------------------------------------------------------------------- diff --git a/package-lock.json b/package-lock.json index 1ad6e89..5214d9f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -422,6 +422,63 @@ } } }, + "gitbook-plugin-bootstrap-callout": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/gitbook-plugin-bootstrap-callout/-/gitbook-plugin-bootstrap-callout-0.1.2.tgz", + "integrity": "sha1-Xeie/nseOMzkPGajzN9lw+r+nOA=", + "dev": true, + "requires": { + "cheerio": "0.19.0" + }, + "dependencies": { + "cheerio": { + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-0.19.0.tgz", + "integrity": "sha1-dy5wFfLuKZZQltcepBdbdas1SSU=", + "dev": true, + "requires": { + "css-select": "1.0.0", + "dom-serializer": "0.1.0", + "entities": "1.1.1", + "htmlparser2": "3.8.3", + "lodash": "3.10.1" + } + }, + "css-select": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-1.0.0.tgz", + "integrity": "sha1-sRIcpRhI3SZOIkTQWM7iVN7rRLA=", + "dev": true, + "requires": { + "boolbase": "1.0.0", + "css-what": "1.0.0", + "domutils": "1.4.3", + "nth-check": "1.0.1" + } + }, + "css-what": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-1.0.0.tgz", + "integrity": "sha1-18wt9FGAZm+Z0rFEYmOUaeAPc2w=", + "dev": true + }, + "domutils": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.4.3.tgz", + "integrity": "sha1-CGVRN5bGswYDGFDhdVFrr4C3Km8=", + "dev": true, + "requires": { + "domelementtype": "1.3.0" + } + }, + "lodash": { + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", + "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", + "dev": true + } + } + }, "gitbook-plugin-collapsible-chapters": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/gitbook-plugin-collapsible-chapters/-/gitbook-plugin-collapsible-chapters-0.1.8.tgz", http://git-wip-us.apache.org/repos/asf/brooklyn-docs/blob/fe43f07b/package.json ---------------------------------------------------------------------- diff --git a/package.json b/package.json index e19dcc7..35ea607 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "dependencies": {}, "devDependencies": { "gitbook-cli": "^2.3.2", + "gitbook-plugin-bootstrap-callout": "^0.1.2", "gitbook-plugin-collapsible-chapters": "^0.1.8", "gitbook-plugin-include-highlight": "^0.2.1", "gitbook-plugin-theme-api": "^1.1.2"
