Commit Graph

1865 Commits

Author SHA1 Message Date
sigurdm@google.com 8e65452aa9 Revert "Fixes for the test framework multitests."
This reverts commit r32892.

Review URL: https://codereview.chromium.org//175113002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32894 260f80e4-7a28-3924-810f-c04153c831b5
2014-02-21 12:54:11 +00:00
sigurdm@google.com 48b2d4f50b Fixes for the test framework multitests.
Allow imports with a metadata annotation.
Allow test keys to be alphanumeric instead of just two digits.

R=whesse@google.com

Review URL: https://codereview.chromium.org//164333013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32892 260f80e4-7a28-3924-810f-c04153c831b5
2014-02-21 12:41:49 +00:00
kustermann@google.com 19e74c6272 Added tools/status_clean.dart script
This script supports two commands:
  deflake:
    This command will go through all status file entries and check if the actual
    testoutcomes we've observed on our buildbots match the status file entries.

    If we have tests marked as flaky which are in fact not flaky, it will write
    a *.status.deflaked file which contains the fixes to the status file.

  fix:
    This command will go through all status files and ensures that all the
    status file lines correspond to existing tests.

    If we have lines that refer to non-existent tests, it will write a
    *.status.fixed file which contains the fixes to the status file.

R=whesse@google.com

Review URL: https://codereview.chromium.org//143453012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32694 260f80e4-7a28-3924-810f-c04153c831b5
2014-02-14 12:21:37 +00:00
sigurdm@google.com 0b1fee8131 Let deferred load work from worker isolates.
If we try to load a deferred library from a worker-isolate we cannot
inject a script tag because we do not have access to the dom. Instead we
make an XMLHttpRequest object and load the code with that.

I tried to take some care of error handling introducing a new exception.

R=floitsch@google.com

Review URL: https://codereview.chromium.org//163733003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32693 260f80e4-7a28-3924-810f-c04153c831b5
2014-02-14 12:12:58 +00:00
sigmund@google.com fdc6d43083 Improve how we handle packages/ HTML imports. This improves resolution of URLs containing
"package/" under the web/ directory. Resolution under 'lib' is the same, but it and gives better suggestions if the path looks wrong. This summarizes what changed:

- source file: lib/b.html

  import to "packages/c/d.html" was error, now is error + suggestion
  import to "../packages/c/d.html" was error, now is error + suggestion
  import to "../../packages/c/d.html" was resolved, now is resolved too

- source file: lib/a/b.html

  import to "packages/c/d.html" was error, now is error + suggestion
  import to "../packages/c/d.html" was error, now is error + suggestion
  import to "../../packages/c/d.html" was error, now is error + suggestion
  import to "../../../packages/c/d.html" was resolved, now is resolved too

- source file: web/b.html

  import to "packages/c/d.html" was and continues to be resolved
  import to "../packages/c/d.html" was error, now is resolved

- source file: web/a/b.html

  import to "packages/c/d.html" was error, now is resolved
  import to "../packages/c/d.html" was and continues to be resolved
  import to "../../packages/c/d.html" was and continues to be resolved

Note: polymer-build and development mode are slightly different: polymer-build
detects and issues an error for bad paths inside lib/. These are not detected by
our package-resolution in loader.dart, but as long as users are not creating
symlinks by hand, Dartium should detect if the paths are wrong.

When we switch to start using pub-serve by default, we should be able to go back
to the web-ui style of using "package:" urls directly in HTML.

R=jmesserly@google.com, kustermann@google.com

Review URL: https://codereview.chromium.org//148913003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32170 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-30 20:51:28 +00:00
ricow@google.com 0306e06b5f Allow copy_coredumps flag on all platforms.
This will have not effect on winodws/mac yet, since the core file will not be there.

Don't try to archive on non linux platforms

I will apply this flag on all vm bots - setting this up on system basis is harder, and this is a no-op on mac/windows

R=ajohnsen@google.com

Review URL: https://codereview.chromium.org//148283006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32117 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-29 11:45:36 +00:00
ricow@google.com b89331831e Fix static warnings introduced by not having pid in base CommandOutput class.
Review URL: https://codereview.chromium.org//137823008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32116 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-29 10:51:53 +00:00
ricow@google.com c2f12c4da6 Add support for copying coredumps to /tmp
This will be used on the bots to be able to archive dumps from unexpectec crashes.

The tools/archive_crash.py tool will be used to actually archive the dumps to gcs and delete the local copies. The reason for the split is to enable developers to actually utilize this locally as well (run tools/test.py in a loop but don't archive the expected crashes). Additionally, this puts the bot specific code in the small python script.

R=whesse@google.com

Review URL: https://codereview.chromium.org//145273024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32111 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-29 09:41:47 +00:00
ricow@google.com 1252f88cff Give default value for builder_tag in test options
Remove now passing test pkgbuild/samples/third_party/angular_todo suppression

Review URL: https://codereview.chromium.org//148893002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32068 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-28 14:47:25 +00:00
ricow@google.com 8b959be6fe Add builder_tag option to tools/test.dart
This will allow us to pass in machine specific tags that describes the setup of a given machine.

Use this to pass in the locale on the pub russian bot and to suppress the two failures we have due to issue 16356

R=kasperl@google.com

Review URL: https://codereview.chromium.org//148463007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32061 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-28 09:55:49 +00:00
iposva@google.com adcb051df3 - Undo inadvertent change to test_runner.dart
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31869 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-16 05:13:41 +00:00
iposva@google.com 39eec505e1 - Update svn:ignore.
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31868 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-16 05:09:35 +00:00
kustermann@google.com db052838a1 Run out.precompiled.js for commandline JS runtimes instead of out.js
R=whesse@google.com

Review URL: https://codereview.chromium.org//136333005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31735 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-13 12:26:32 +00:00
kustermann@google.com 54b71bdbe2 Reaply "Use a real package-root for all of our samples (and tests inside a package) instead of buildDir/packages/"
R=whesse@google.com

Review URL: https://codereview.chromium.org//133653004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31694 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-10 15:15:37 +00:00
kustermann@google.com 8afb1d4844 Revert "Use a real package-root for all of our samples (and tests inside a package) instead of buildDir/packages/"
Review URL: https://codereview.chromium.org//130743005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31693 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-10 12:58:33 +00:00
kustermann@google.com 76e4bdeb0c Use a real package-root for all of our samples (and tests inside a package) instead of buildDir/packages/
For all tests that depend on other packages (e.g. samples) we can
 - use packages from pub.dartlang.org
 - use packages from pub.dartlang.org with overrides for the packages we have
   in the dart repository.

This CL does NOT include test-specific package-roots for dartium. Dartium will request a URL containing
"packages" when it encounters a package import. Our HTTP server will then serve from buildDir/packages.
This needs to change when we have test specific VMOptions for dartium.

For normal tests (without a pubspec.yaml on the path to dart/, we still use buildDir/packages).

R=ricow@google.com, whesse@google.com

Review URL: https://codereview.chromium.org//126173002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31691 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-10 12:29:55 +00:00
kustermann@google.com 338fabdb6c Cancel stdout/stderr subscriptions once subprocesses are dead, add more debugging information in case the debug timer expires
R=whesse@google.com

Review URL: https://codereview.chromium.org//128703002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31649 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-09 09:04:46 +00:00
kustermann@google.com 2dca82b247 Make TestUtils.copyDirectory() more robust by ensureing arguments are a native path
Review URL: https://codereview.chromium.org//126053003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31550 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-07 15:38:15 +00:00
kustermann@google.com 704fa7b241 Convert statusfile path to native path
R=ricow@google.com

Review URL: https://codereview.chromium.org//125973002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31544 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-07 14:05:30 +00:00
kustermann@google.com e363ffb931 Enable pkgbuild testsuite on pub builders
R=ricow@google.com

Review URL: https://codereview.chromium.org//125833002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31537 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-07 10:12:10 +00:00
kustermann@google.com dc24212755 Added PkgBuildTestSuite (aka 'pkgbuild')
This CL adds
 - support for fetching dependencies via 'pub get' of samples/packages
 - support for building applications/samples via 'pub build' (or a custom
   build.dart file)
 - pkg/pkgbuild.status: Status files for all package checkouts/builds
 - the '--use-public-packages' option to test.dart
 - the CleanDirectoryCopyCommand, PubCommand, ModifyPubspecYamlCommand commands

The test suite can be executed with:
 $ ./tools/test.py -mrelease --use-sdk pkgbuild
 $ ./tools/test.py -mrelease --use-sdk --use-public-packages pkgbuild

R=ricow@google.com

Review URL: https://codereview.chromium.org//122443003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31535 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-07 09:36:27 +00:00
kustermann@google.com 97e4f770dc Added ScriptCommand,ScriptCommandOutputImpl classes
R=ricow@google.com

Review URL: https://codereview.chromium.org//123213002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31477 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-06 15:52:51 +00:00
kustermann@google.com b395778f71 Extended ProcessCommand/RunningProcess with Command specific working directory.
R=ricow@google.com

Review URL: https://codereview.chromium.org//123213003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31476 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-06 15:27:13 +00:00
kustermann@google.com c3793cc8c5 Added convenience function for reading status file expectations
R=ricow@google.com

Review URL: https://codereview.chromium.org//113943007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31472 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-06 13:56:39 +00:00
sgjesse@google.com a89aa53071 Make the Platform.environment return value an unmodifiable map
R=ajohnsen@google.com, kustemann@google.com
BUG=http://dartbug.com/15872

Review URL: https://codereview.chromium.org//123263003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31468 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-06 10:18:22 +00:00
kustermann@google.com 18a8f25608 Command class hieracy refactoring, environmentOverride extraction
R=ricow@google.com, whesse@google.com

Review URL: https://codereview.chromium.org//118783003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31269 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-19 13:01:46 +00:00
kustermann@google.com 667c9ec4bf Make sure we mark all depending commands (transitively!) UnableToRun if a command fails
R=whesse@google.com

Review URL: https://codereview.chromium.org//107153004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31241 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-18 21:54:45 +00:00
kustermann@google.com ca307461d0 test.py: Removed JUnitTestSuite, since it's no longer used
R=whesse@google.com

Review URL: https://codereview.chromium.org//113713006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31214 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-18 08:48:00 +00:00
whesse@google.com 539d41deb1 Remove unused parameter from test infrastructure: use_unittest_controller.
BUG=
R=kustermann@google.com

Review URL: https://codereview.chromium.org//104963003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30988 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-09 15:18:11 +00:00
whesse@google.com c8bfa98017 Test infrastructure: add retry to browser controller sending "done" message.
BUG=
R=kustermann@google.com

Review URL: https://codereview.chromium.org//107513004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30950 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-06 16:38:15 +00:00
kustermann@google.com eb09d1e40b co19-roll to r672
Review URL: https://codereview.chromium.org//100363003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30854 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-04 13:00:12 +00:00
kustermann@google.com 20b8ddbfee Remove the command-specific outcome temporarily when writing out the .test-outcome.log file
TBR=ricow@google.com

Review URL: https://codereview.chromium.org//96603002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30773 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-29 09:28:15 +00:00
ricow@google.com bae4d99ce1 Add debug information to verify that we actually get the onDone event send to the driver page.
I am aware that we should not clutter up the message that we show to developers, but I think it is important to validate that we actually send the onDone message to the driver page.

We should also put in functionality for tracking network errors in the browser_controller generated js (+potentially retrying the send of the message)

R=kustermann@google.com

Review URL: https://codereview.chromium.org//96503002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30771 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-29 08:57:47 +00:00
kustermann@google.com 26f065bdb2 Add .test-outcome.log support to test.dart
R=ricow@google.com

Review URL: https://codereview.chromium.org//95603002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30768 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-29 08:29:20 +00:00
kustermann@google.com fc15ac395d Remove left-over print statement in test_runner.dart
Review URL: https://codereview.chromium.org//95593002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30766 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-28 17:34:01 +00:00
kustermann@google.com 5ed5e5b17a Added debug timer to test.dart
We are seeing a lot of test.dart timeouts on our browser bots. This is an
attempt to get more information on what is going on.

R=ricow@google.com

Review URL: https://codereview.chromium.org//88803002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30765 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-28 16:20:28 +00:00
kustermann@google.com e634fb20a4 Make status updates after 10 seconds + fix handling of status updates
R=ricow@google.com

Review URL: https://codereview.chromium.org//94213002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30748 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-28 08:50:58 +00:00
kustermann@google.com eeee37127b Fix after upgrading to new checked-in binary
R=ricow@google.com

Review URL: https://codereview.chromium.org//91693002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30718 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-27 14:53:46 +00:00
kustermann@google.com bb54b776ba Checked-in binary update to v1.0.0.3
R=ricow@google.com

Review URL: https://codereview.chromium.org//91473002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30717 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-27 14:17:44 +00:00
kustermann@google.com e70a3e5a21 Print again how many compilations were skipped
R=ricow@google.com

Review URL: https://codereview.chromium.org//88823003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30699 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-27 08:27:21 +00:00
kustermann@google.com 8a9d4c085e Whitelist nonzero content_shell exitcode
R=ricow@google.com

Review URL: https://codereview.chromium.org//88443002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30670 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-26 14:48:41 +00:00
kustermann@google.com c23917be9b Print events only to the console and never to the DOM
IE9 does not have a console, so events were printed to the DOM. But since we get
all events anyway when using the browser controller, there is no need to print
it to the DOM.

R=ricow@google.com

Review URL: https://codereview.chromium.org//85853002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30630 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-25 14:35:50 +00:00
ricow@google.com 52a12f1b37 Remove old warning code for wrong usage of warnings in co19
Review URL: https://chromiumcodereview.appspot.com//85303004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30621 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-25 12:54:15 +00:00
kustermann@google.com 6c04b9a0b2 Followup on co19-roll to r667, marked co19/Language/12_Expressions/32_Type_Test_A02_t04 as failing in minified mode
Review URL: https://codereview.chromium.org//79143005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30513 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-21 12:09:52 +00:00
kustermann@google.com 8b103390e2 Make sure variable names used in status files are available in the environment
Previously we didn't validate that a variable name used in a status file
expression was available.

It wasn't surfaced, since lookups in Map objects return null if the key is
missing and calling 'toString()' on 'null' doesn't throw an exception.

BUG=http://dartbug.com/12959
R=ricow@google.com

Review URL: https://codereview.chromium.org//78723002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30502 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-21 09:54:36 +00:00
kustermann@google.com 3d910a2a9a Remove filtering of analyzer warnings/errors by filename
The only files that are now not analyzed are the patch files in
"sdk/lib/_internal/lib" and test files (i.e. files ending with "_test.dart")

R=ricow@google.com

Review URL: https://codereview.chromium.org//78483002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30471 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-20 14:06:34 +00:00
kustermann@google.com 8649be6036 Implement a periodic timer which sends the current state of a browser test back to the browser controller
R=ricow@google.com

Review URL: https://codereview.chromium.org//77763004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30468 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-20 13:32:16 +00:00
kustermann@google.com e3d8608ca2 test.py: Sending JSON between test_controller.js <-> browser_controller
Currently test.py will look for FAIL/PASS messages in the DOM to determine if a
test has failed or not. test_controller.js will add these PASS/FAIL messages to
the DOM (in addition to other messages).

This approach has several issues:
- The test itself could create nodes in the DOM containing FAIL/PASS. This means
  that the outcome of a test cannot be reliably determined.
- The test ifself can remove nodes from the DOM (e.g. setting
  document.body.innerHTML). This could result in a situation where the
  stacktraces/... test_controller.js prints to the DOM are lost.
- It is unclear which parts of the DOM we see in test failure messages
  (reported by test.py) come from the test itself and which parts come from
  test_controller.js.

This CL tries to fix this by recording all events that happend with global
variables in test_controller.js and send back a JSON string with information
about
  - debug messages
  - posted messages
  - print() calls of the test
  - DOM
  - errors (from window.onerror, script.onerror ...)

Furthermore this CL fixes unittest to report
unittest-suite-success/unittest-suite-fail instead of unittest-suite-done (which
is broken).

R=ricow@google.com

Review URL: https://codereview.chromium.org//36913002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30407 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-19 12:54:41 +00:00
ricow@google.com 1fd9f4b774 Print drt exitcode when we pass test but crash before exiting
R=kustermann@google.com

Review URL: https://codereview.chromium.org//60763004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30401 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-19 12:08:54 +00:00
kustermann@google.com af29f7901f Removed assert for nonexistent use_browser_controller option
TBR=ricow@google.com

Review URL: https://codereview.chromium.org//75243002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30344 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-18 12:59:20 +00:00