Left: | ||
Right: |
OLD | NEW |
---|---|
1 <!-- | 1 <!-- |
2 HACKING.md | 2 HACKING.md |
3 Copyright 2013 Canonical Ltd. | 3 Copyright 2013 Canonical Ltd. |
4 This work is licensed under the Creative Commons Attribution-Share Alike 3.0 | 4 This work is licensed under the Creative Commons Attribution-Share Alike 3.0 |
5 Unported License. To view a copy of this license, visit | 5 Unported License. To view a copy of this license, visit |
6 http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative | 6 http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative |
7 Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA. | 7 Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA. |
8 --> | 8 --> |
9 | 9 |
10 # Juju GUI Charm Development # | 10 # Juju GUI Charm Development # |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
62 | 62 |
63 There are two types of tests for the charm: unit tests and functional tests. | 63 There are two types of tests for the charm: unit tests and functional tests. |
64 Long story short, to run all the tests: | 64 Long story short, to run all the tests: |
65 | 65 |
66 make test JUJU_ENV="myenv" | 66 make test JUJU_ENV="myenv" |
67 | 67 |
68 In the command above, "myenv" is the juju environment, as it is specified in | 68 In the command above, "myenv" is the juju environment, as it is specified in |
69 your `~/.juju/environments.yaml`, that will be bootstrapped before running the | 69 your `~/.juju/environments.yaml`, that will be bootstrapped before running the |
70 tests and destroyed at the end of the test run. | 70 tests and destroyed at the end of the test run. |
71 | 71 |
72 Note that the test will not work using an LXC environment. The test | |
frankban
2014/03/05 13:07:54
Thank you for this! To be more explicit, we could
bac
2014/03/05 15:23:24
Done.
| |
73 co-locates the juju-gui on the bootstrap node, which is not possible in LXC. | |
74 | |
72 Please read further for additional details. | 75 Please read further for additional details. |
73 | 76 |
74 ### Unit Tests ### | 77 ### Unit Tests ### |
75 | 78 |
76 The unit tests do not require a functional Juju environment, and can be run | 79 The unit tests do not require a functional Juju environment, and can be run |
77 with this command:: | 80 with this command:: |
78 | 81 |
79 make unittest | 82 make unittest |
80 | 83 |
81 Unit tests should be created in the "tests" subdirectory and be named in the | 84 Unit tests should be created in the "tests" subdirectory and be named in the |
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
235 sent by the client (usually the Juju GUI) and by the Juju API server. | 238 sent by the client (usually the Juju GUI) and by the Juju API server. |
236 As mentioned, juju-deployer works on its own sandbox and uses its own API | 239 As mentioned, juju-deployer works on its own sandbox and uses its own API |
237 connections, and for this reason the WebSocket traffic it generates is not | 240 connections, and for this reason the WebSocket traffic it generates is not |
238 logged. | 241 logged. |
239 | 242 |
240 Sometimes, while debugging, it is convenient to restart the builtin server | 243 Sometimes, while debugging, it is convenient to restart the builtin server |
241 (which also empties the bundle deployments queue). To do that, run the | 244 (which also empties the bundle deployments queue). To do that, run the |
242 following in the Juju GUI machine: | 245 following in the Juju GUI machine: |
243 | 246 |
244 service guiserver restart | 247 service guiserver restart |
OLD | NEW |