Skip to content

Development and Testing

Jesse Jurman edited this page Mar 31, 2015 · 19 revisions

##Installing

  1. install 32 bit java (ensure that it is listed on your path)
  2. install node
  3. in the root directory, run npm install
  4. npm run build
  5. Launch in your browser of choice bin\scratch.swf

if it fails, try cloning the repo again and doing a fresh npm install

##Debugging (in IntelliJ and Chrome)

Installing Flash Debug for Chrome

  1. Navigate to chrome://plugins/
  2. Disable Adobe Flash Player
  3. Install the debug version for Chromium and Opera here: http://www.adobe.com/support/flashplayer/downloads.html
  4. Navigate to chrome://plugins/
  5. Expand the details tab (located at the top right of the table)
  6. Make sure that the Chrome Flash player (under Google\Chrome\Applications\...) is disabled, and the one under system32\Macromed\Flash\... is enabled.

image

Setting the Debugger in IntelliJ

You can follow these instructions here specifically, under Managing build configurations and their settings

  1. Open the project as a folder in IntelliJ
  2. Open the Project Structure dialog (ctrl+shift+alt+s)
  3. Under Project Settings, select Modules
  4. Remove the already existing accessible-scratch folder (this won't delete your folders)
  5. Select Add > New Module
  6. Use the following settings image
  7. If you need to add the flex sdk, first click the ... near Flex/AIR sdk
  8. Add a new Flex/AIR sdk, and select the following directory in the file browser: \accessible-scratch\node_modules\flex-sdk\lib\flex_sdk
  9. Click OK to continue with the settings page in step 5.
  10. Name the module accessible-scratch (and delete the preceding version of the name in the directories) image
  11. You'll need to edit some settings for the modules, under Project Structure, set the Main class to Scratch and the Output folder to ...\accessible-scratch\bin image
  12. Make sure you have all of the following dependencies listed below in the dependencies tab. image
  13. Under the compiler options for the module, add the conditional compiler options for SCRATCH::allow3d, which you can set to true
  14. Paste the following text under Additional compiler options
 --static-link-runtime-shared-libraries=true --accessible
  1. The final page should look something like this... image
  2. You can Make Project to validate that you set up everything correctly.
  3. After that you should be able to click on the bug icon to start debugging in chrome