Eine Idee, wie Sie Karma Unit Tests innerhalb von VSTS ausführen können? Müssen sie in den Visual Studio Test Runner integriert werden oder gibt es einen besseren Weg?Visual Studio Team Services und Karma
Das Projekt ist eine rein clientseitige statische SPA-Website, daher gibt es keine Visual Studio-Lösung oder -Projekt.
Auch wenn ich versuche, Karma über NPM zu starten, scheint es, als ob PhantomJS nicht auf dem Agenten starten würde.
Logs aus dem Körperbau:
2016-08-03T02:45:44.9647601Z webpack: bundle is now VALID.
2016-08-03T02:45:44.9717626Z [32m03 08 2016 02:45:44.968:INFO [karma]: [39mKarma v0.13.22 server started at http://localhost:9876/
2016-08-03T02:45:44.9767811Z [32m03 08 2016 02:45:44.976:INFO [launcher]: [39mStarting browser PhantomJS
2016-08-03T02:46:44.9784272Z [33m03 08 2016 02:46:44.977:WARN [launcher]: [39mPhantomJS have not captured in 60000 ms, killing.
2016-08-03T02:46:46.9783856Z [33m03 08 2016 02:46:46.977:WARN [launcher]: [39mPhantomJS was not killed in 2000 ms, sending SIGKILL.
2016-08-03T02:46:48.9792421Z [33m03 08 2016 02:46:48.978:WARN [launcher]: [39mPhantomJS was not killed by SIGKILL in 2000 ms, continuing.
2016-08-03T02:46:49.1602394Z npm ERR! Test failed. See above for more details.
2016-08-03T02:46:49.1722407Z ##[debug]rc:1
2016-08-03T02:46:49.1722407Z ##[debug]success:false
2016-08-03T02:46:49.1722407Z ##[debug]taskRunner fail
2016-08-03T02:46:49.1732408Z ##[debug]task result: Failed
2016-08-03T02:46:49.1782402Z ##[error]Npm failed with error: C:\Program Files\nodejs\npm.cmd failed with return code: 1
2016-08-03T02:46:49.1962405Z Finishing task: Npm
2016-08-03T02:46:49.2032405Z ##[error]System.Exception: Task Npm failed. This caused the job to fail. Look at the logs for the task for more details.
2016-08-03T02:46:49.2042402Z ##[error] at Microsoft.TeamFoundation.DistributedTask.Worker.JobRunner.Run(IJobContext jobContext, IJobRequest job, IJobExtension jobExtension, CancellationTokenSource tokenSource)