Commit Graph

16 Commits

Author SHA1 Message Date
carlad
517a3b04f7 Revert "Revert "Merge branch 'master' of github.com:travis-ci/travis-api""
This reverts commit 171b9c57c7.
2015-01-27 16:22:30 +01:00
Konstantin Haase
171b9c57c7 Revert "Merge branch 'master' of github.com:travis-ci/travis-api"
This reverts commit 1b8f77ab36, reversing
changes made to 79a4a9ad13.
2015-01-27 14:39:36 +01:00
carlad
f39d931857 update response status ans specs 2015-01-27 13:31:12 +01:00
Tyranja
a9c31fa5e9 Extract cancel and restart builds and jobs into sidekiq worker
See below for all the commit messages squashed into this one...
add a test

delete empty space

add job_cancellation worker

change id

change job_id param

add job restart worker

add require to sidekiq.rb

change params

add test for job restart and cancellation

add test for job restart

update build.rb improve build spec

update job restart with correct response, add test to chack for correct response when restarting job
2015-01-26 17:29:13 +01:00
Tyranja
057e9f0379 add Sidekiq for cancelling build
:
add require sidekiq to the sidekiq.rb

update Gemfile.lock

bump travis-sidekiqs

correct require statement

fix another request

connect to the database

add current user

add current user correctly

add current user correctly

add puts to see were in the condition we are

missing invertted comma

add comments to the worker

I HAVE NO IDEA

Revert "I HAVE NO IDEA"

This reverts commit 8bd1259bf4ea1b479f9391847a4700b7b15efe57.

change the id and source to symbols in the params because siedekiq expects that

add more printout

setup database connection, metrics and notification

correct the test
2015-01-23 14:43:54 +01:00
carlad
9b4d121956 refactor buildcancellation worker 2015-01-22 14:41:38 +01:00
Piotr Sarnacki
39260c3918 Fix specs after travis-core update 2013-11-28 18:08:39 +01:00
Piotr Sarnacki
f19de9d134 Implement jobs/:id/cancel and builds/:id/cancel endpoints 2013-08-08 14:25:20 +02:00
Piotr Sarnacki
b6a351c766 Convert params['ids'] to array
Services like find_builds can accept :ids as a param, but it needs to be
an array, string will be passed to find and converted into integer.
2013-07-09 15:18:31 +02:00
Piotr Sarnacki
f2d768080f Return last builds on each branch for /builds?branches=true
This is a hack to fix travis-ci/travis-web#123 easier. A proper solution
would be to refactor how /branches work.
2013-01-26 01:12:47 +01:00
Piotr Sarnacki
c6e3c29a57 Load the data for integration tests upfront
We can do it, because we use :transaction strategy with DatabaseCleaner,
which starts transaction before each test and rollbacks after it. That
way data before each test is consistent.

The big advantage of such approach is that tests are fast now - we need
to only load Scenario data once.

One of the drawbacks, on the other hand, is that we need to always load
this data, even if no integration tests need running.

We can try to be smart about it and check if any integration tests are
loaded.
2013-01-26 00:00:42 +01:00
Sven Fuchs
1b9bc9b039 fix specs for cors 2012-10-11 14:07:51 +02:00
Sven Fuchs
8abd6fa150 manual redirects and rewrite rules for supporting v1 style resources 2012-10-10 01:48:22 +02:00
Sven Fuchs
903f249cfb moar refactoring on responders, fix specs 2012-10-09 18:28:46 +02:00
Sven Fuchs
5a6f34005c comment out result images for now since i cant get this to work 2012-10-02 21:12:41 +02:00
Sven Fuchs
289f7c1486 start porting api integration tests 2012-10-02 16:39:38 +02:00