blackberry-webworks/BB10-Webworks-Packager — Issue #36: JavaScript API: Packager doesn't detect it when an API is missing a required file or contains a non .js file
Author: ishneur
Created: 2012-03-01 19:19:56+00:00
State: open
Labels: Bug

Description:

This issue applies to the following acceptance criteria of US15269: Packager should report an error and terminate if the referenced API is not a valid API structure.

Scenario 1:
1. In one of the API folders under "\Framework\ext", remove index.js/client.js or both
2. Build an application that uses this API

Expected: Packager reports an error
Actual: Bar file is created and can be run. When trying to use the API in the app it doesn't work (either nothing happens or returns "undefined").

Scenario 2:
1. In one of the API folders under "\Framework\ext", place a non .js file - e.g. a .txt or .png file.
2. Build an application that uses this API

Expected: Packager reports an error
Actual: Bar file is created and can be run. When trying to run this app, it opens up but only a blank page appears. After several seconds the app closes on its own.

Builds tested: http://mac-ci:9000/job/BB10-Webworks-Packager-next-packageAPI/9/, http://mac-ci:9000/job/BB10-Webworks-Packager-next-packageAPI/11/