Skip to content

Commit

Permalink
Merge pull request #76 from arthurakay/master
Browse files Browse the repository at this point in the history
Updating test README and setup
  • Loading branch information
arthurakay committed Apr 4, 2014
2 parents 888013c + 36d4293 commit 5ca438c
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 15 deletions.
24 changes: 14 additions & 10 deletions app/test/README.md
Expand Up @@ -9,29 +9,33 @@ To test App Inspector for Sencha, we have chosen to use Siesta because:

## Setup

In order to run the tests, you'll first need to setup a local server with the following architecture:
In order to run the tests, you'll first need to understand the project architecture:

sencha.local (local hostname)
~/parent_folder/

/AppInspector/
/AppInspector/ (the Git repo)
/app/
/test/
index.html (view the test suite here)
/_ext/
/_ext/ (can be a symlink)
/ext-4.2.1.883/ (the fully unpacked ZIP)
/ext-5.0.0/ (eventually)
/_touch/
/_touch/ (can be a symlink)
/touch-2.3.1/ (the fully unpacked ZIP)

We are testing App Inspector's *AI.util* classes against the examples which ship with the Sencha frameworks. Because of
cross-domain issues, these examples must be run on the same domain as our test code... hence creating *sencha.local*
on your local machine.
We are testing App Inspector's *AI.util* classes against examples which ship with the Sencha frameworks for simplicity.
Because of cross-domain issues, these examples must be run on the same domain as our test code... so we use Node.js/Grunt to start a localhost.

The */_ext/* and */_touch/* folders can be symbolic links, but their placement and naming is key to the testing architecture.

## Run the Tests

In your browser you should now be able to view http://sencha.local/AppInspector/app/test/index.html, which loads the
Siesta test suite.
From your terminal, run the command:

`grunt test`

...which loads the Siesta test suite in your browser running on a localhost.

You can run the tests individually or batched simultaneously - though the latter sometimes reports false errors.
6 changes: 1 addition & 5 deletions app/test/index.js
@@ -1,7 +1,7 @@
var Harness = Siesta.Harness.Browser;

Harness.configure({
title : 'AppInspector Test Suite'
title : 'AppInspector Test Suite'
//autoCheckGlobals : true
});

Expand All @@ -13,7 +13,6 @@ Harness.start(
'AI' : '../AppInspector/app'
},

// hostPageUrl : 'http://sencha.local/_touch/touch-2.3.1/examples/list/index.html',
hostPageUrl : '../../../_touch/touch-2.3.1/examples/list/index.html',

items : [
Expand All @@ -34,8 +33,6 @@ Harness.start(
'AI' : '../AppInspector/app'
},

//hostPageUrl : 'http://sencha.local/_ext/ext-4.2.1.883/examples/personel-review/index.html',
// hostPageUrl : 'http://localhost/_ext/ext-4.2.1.883/examples/kitchensink/#basic-panels',
hostPageUrl : '../../../_ext/ext-4.2.1.883/examples/kitchensink/#basic-panels',

items : [
Expand All @@ -52,7 +49,6 @@ Harness.start(
'AI' : '../AppInspector/app'
},

// hostPageUrl : 'http://sencha.local/_ext/ext5-qa/ext/examples/kitchensink/#basic-panels',
hostPageUrl : '../../../_ext/ext5-qa/ext/examples/kitchensink/#basic-panels',

items : [
Expand Down

0 comments on commit 5ca438c

Please sign in to comment.