Commit Graph

8 Commits

Author SHA1 Message Date
Vojta Jina fb01551620 chore: allow running Dart/JS Karma at the same time
Use `9876` port for JS.
Use `9877` port for Dart.
2014-10-09 13:50:25 -07:00
Vojta Jina cfc5fdc60d chore: use es6-module-loader
Switch Traceur to use modules=“instantiate” and use es6-module-loader.
This setup supports cyclic dependencies.
2014-10-07 17:35:22 -07:00
Chirayu Krishnappa 774901c225 chore(karma): use ChromeCanary as the default for JS
Closes #56
2014-10-07 16:48:03 -07:00
Tobias Bosch 85b5543f62 feat: travis-ci integration 2014-09-29 16:33:53 -07:00
Tobias Bosch c79f0c3472 refactor: simplify and make tests work in JS and Dart
* remove `wraps` syntax enhancements for imports
  and support new `import * as module from ...` syntax

  - default imports are the wrong construct for importing
    everything from a module

* moved tests from transpiler to jasmine and karma

  - transpiler tests are included when running karma in main project folder
  - transpiler is reloaded after every test run in karma,
    so no need to restart karma when the transpiler has been changed.
  - removed own gulp build for transpiler and `postinstall.sh`
    as they are no more needed.
  - transpiler tests are now executed in Dart AND JavaScript (used to be executed
    only in Dart), which allowed to catch some bugs (see the bug with the
    import specification above).

* made tests work in dart as well by using the following hack:

  - dependencies are loaded from the `build` folder, which makes
    running `gulp build` necessary before running karma for dart
  - for this to work,
    the dependencies are included in main `pubspec.yaml` of project
  - reason for the hack: `karma-dart` loads all `packages` urls
    directly from disc (should rather use the karma file list)

* added explicit annotations `FIELD`, `ABSTRACT`, ... to `facade/lang.*`

  - needed for now that we can run tests and don't get errors for undefined
    annotations.

* added `README.md` with details about the build and tests
2014-09-28 21:50:38 -07:00
Tobias Bosch 39c03e67e6 refactor: rename `js2dart` to `transpiler` 2014-09-26 17:44:42 -07:00
Tobias Bosch c8cf03f200 refactor: move rtts-assert into `modules` directory
The rtts assertion lib is only needed for js, 
but it should be treated like any other module (e.g. facade, …)
2014-09-26 17:36:57 -07:00
Vojta Jina c3b442ea53 chore: karma with JS, Dart
Note: karma with dart is still not working
because of how `karma-dart` loads `package:…` dependencies.

Usage:
```
karma start karma-js.conf.js
karma start karma-dart.conf.js
```

Make sure to set `DARTIUM_BIN` env variable.

Refactors `js2dart`:
- live outside of the traceur module (`tools/js2dart/index.js`)
  so it can be reused by gulp and karma
- automatically build the sources in memory,
  so that `js2dart` can be used without running `gulp build` first
- provide a way to specify the moduleName of a compilation run
  independently of the input filename. This helps error messages
  and source maps (not yet enabled) to report the correct file name

Changes project setup:
- add module `test_lib` that contains the primitives for tests
  (e.g. `describe`, `it`, …)
- clean up some sources that had errors in them
- module names in transpiled js and dart files don’t contain
  `lib`, `test` nor `src` any more (e.g. `di/di`).
2014-09-26 16:53:54 -07:00