Commit Graph

62 Commits

Author SHA1 Message Date
Hiro Asari
3f30eecc7d Add granular permission levels to User
Display buttons for job control only if the user has permission to do
so.
2013-11-06 15:00:46 -05:00
Piotr Sarnacki
018eafe84b Fix problem with getting started template rendering on first sync
When first sync template is displayed, user usually doesn't have any
repos, which also triggers rendering of getting started template. The
fix for this is to handle the action to render getting started page on
first sync and do nothing in such case.

I also added a test to ensure that it works correctly.
2013-10-29 20:48:27 +01:00
Piotr Sarnacki
b5297d7800 Update code for newest ember-model 2013-10-18 13:41:10 +02:00
Josh Kalderimis
c699d48337 Merge branch 'updated-styles' 2013-10-14 17:37:28 +02:00
Henrik Hodne
e3e96aca73 Remove more trailing whitespace 2013-10-07 17:07:33 -05:00
Josh Kalderimis
63c8c59744 remove some whitespace 2013-10-07 23:52:17 +02:00
Aaron Hill
7218655cf4 Added tests for clearing log when a job is started or requeued 2013-10-04 16:51:28 -04:00
Lukasz Sarnacki
226c5bb42b More github references replaced with links
Github links will be created for following references:
* @username
* gh-1 (for issue #1)
2013-09-01 13:43:21 +02:00
Lukasz Sarnacki
44c7c627fb Replace github refference with link travis-ci/travis-ci#1266
Github issue refference is now replaced with github issue url.
This covers following refferences:
* #Num
* User#Num
* User/Project#Num
2013-09-01 13:36:24 +02:00
Piotr Sarnacki
30d273a648 Fix specs 2013-08-29 01:19:35 +02:00
Piotr Sarnacki
7be461758c Fix specs 2013-08-26 17:01:27 +02:00
Piotr Sarnacki
359c97cad0 Rewrite specs from jasmine to qunit 2013-07-31 13:29:45 +02:00
Piotr Sarnacki
5fea9d1d7b Change spec runner to qunit
New ember-testing additions can be plugged into qunit without any
changes, so the easiest way to start using it is to rewrite our tests to
qunit.
2013-07-30 17:12:58 +02:00
Piotr Sarnacki
ebb5f17058 Fix tests with new Ember version 2013-05-15 18:46:41 +02:00
Piotr Sarnacki
3f30f3eec9 sign out before resetting app 2013-05-15 17:23:51 +02:00
Piotr Sarnacki
07cd8233d4 Use $.ajax when testing to not break jquery.mockjax 2013-05-15 17:23:48 +02:00
Mathias Meyer
d82116d68f Fix GitHub URL test. 2013-05-10 17:09:40 +02:00
Mathias Meyer
d04988138d Fix specs and expectations for URL changes. 2013-05-10 17:05:45 +02:00
Piotr Sarnacki
df9db80c42 A few improvements for tabs on repos list
* if user is logged out, the default tab should be 'recent'
* when user logs in, the tab is switched to 'my repositories'
* when user logs out, my repositories is hidden again and tab is
  switched to 'recent'
2013-04-30 02:45:16 +02:00
Piotr Sarnacki
e23d16c135 Sign out user before running tests 2013-04-29 23:00:13 +02:00
Piotr Sarnacki
f3570acf7c Comment failing tests, sidebar is temporarily limited. 2013-04-29 22:58:57 +02:00
Piotr Sarnacki
c7561ee13e Properly display matrix keys when build does not have all keys
When additional items are included into matrix via 'matrix.include' key
in .travis.yml they may contain config keys, which are not available on
build.

For example build can contain only 'rvm' key, but we may add the
following include:

    matrix:
      include:
        - rvm: '2.0.0'
          env: 'FOO=bar'

In such case, we need to take into account also keys from additional
job, not only from the build.

(closes #172)
2013-04-06 01:48:32 +02:00
Piotr Sarnacki
957d8a01ab Merge branch 'sidebar-tabs'
Conflicts:
	assets/scripts/spec/support/conditions.coffee
2013-04-05 19:26:24 +02:00
Piotr Sarnacki
39d0202d7a Fix specs, add styling for firefox 2013-04-05 18:09:00 +02:00
Piotr Sarnacki
7996358f01 Fix fetching log in firefox when Location header is unavailable 2013-04-02 20:17:24 +02:00
Piotr Sarnacki
17923af973 Fix expanding folds on firefox 2013-03-29 23:25:05 +01:00
Piotr Sarnacki
ac675e5918 Fix tests 2013-03-29 22:53:57 +01:00
Piotr Sarnacki
745b3a0167 Wait more time in ChunkBufferSpec, to make it more reliable 2013-03-27 20:05:38 +01:00
Piotr Sarnacki
f1adbf8f20 Improve log handling
* don't fetch log content on Travis.Log init
* use timeout in ChunkBuffer instead of Ember.run.later
* remove timeout when log is finalized
2013-03-22 01:25:23 +01:00
Piotr Sarnacki
c0d23f5579 Be more specific when catching 'URL not found' error, also add test 2013-03-19 21:39:38 +01:00
Piotr Sarnacki
65254b70da Fix cutting too long logs 2013-03-19 16:07:21 +01:00
Piotr Sarnacki
80317050ff Fix specs 2013-03-14 19:59:20 +01:00
Piotr Sarnacki
296bff56f1 Fix specs 2013-03-14 15:43:19 +01:00
Piotr Sarnacki
e02ece9424 Merge branch 'master' into ps-ember-update
Conflicts:
	assets/scripts/app/models/artifact.coffee
	assets/scripts/app/store.coffee
	assets/scripts/app/views/job.coffee
	assets/scripts/spec/spec_helper.coffee
2013-03-12 13:47:20 +01:00
Piotr Sarnacki
b289d3966b Finish ChunkBuffer implementation and integrate it with Artifact 2013-03-09 22:01:06 +01:00
Piotr Sarnacki
b4022f5f67 A few improvements for ChunkBuffer
* insert available items at once
* allow to use pushObject on buffer itself
* add a test using arrayObserver to make sure that it fires only when
  elements are added to arrangedContent
2013-03-09 22:01:05 +01:00
Piotr Sarnacki
d549831c22 Add chunk buffer 2013-03-09 22:01:05 +01:00
Piotr Sarnacki
6c10592864 Increase wait in job_spec 2013-03-07 02:04:51 +01:00
Piotr Sarnacki
25079b8d79 Move hacks for phantomjs to spec.html
This ain't pretty, but I just want to see if it helps to fix specs on
phantomjs, I may move them to separate file and take into account in
Assetfile later.
2013-03-07 01:59:15 +01:00
Piotr Sarnacki
8d9b36c0a6 Remove Date hack, which was used for timeago 2013-03-06 14:43:13 +01:00
Piotr Sarnacki
4337949dd4 Fix the rest of the specs 2013-03-04 13:29:00 +01:00
Piotr Sarnacki
712389efdb Fix more specs 2013-03-04 03:46:04 +01:00
Piotr Sarnacki
c6d1f4fa59 Fix a few more integration tests 2013-02-28 15:56:55 +01:00
Piotr Sarnacki
02ff533774 Fix integration tests running and 2 first tests 2013-02-28 15:54:48 +01:00
Piotr Sarnacki
46f7e6bba0 Fix remaining ember-data and pusher updates issues
When records are updated by pusher events, we should not mark them as
dirty - we don't modify them on client side anyway.
2013-02-26 04:37:23 +01:00
Piotr Sarnacki
83fb0ebb2c Fix incomplete implementation 2013-02-21 23:22:54 +01:00
Piotr Sarnacki
23a58866bd Fix LimitedArray to work properly with SortableMixin 2012-12-14 04:31:28 +01:00
Piotr Sarnacki
27fe85989a Make rendering long logs faster when rendering huge chunks at once
After change log rendering method, to append HTML elements instead of
rerendering the entire thing, the case of gradual rendering of a log
started to behave much better (because we just append new elements), but
the initial render took a bit longer, because of the fact that appending
large separate HTML elements to DOM at once is not a good idea.

In order to make the situation better I added simple optimization.
Elements are added to DocumentFragment node before inserting to DOM and
appended to DOM only after all elements are processed. That way, when
log needs to be rendered all at once, we will not do any DOM operations
until log is ready.
2012-12-05 21:29:41 +01:00
Piotr Sarnacki
fc40190c29 Optimize log viewer
Till now, log viewer was rendered in handlebars, which was the simplest
solution, but it had a major drawback - every append to log caused it to
rerender which was not efficient and memory consuming.

The new approach is to make Travis.Log interpret the log and send lines
with instructions to the view, so for example if view should add a line,
it gets something like:

    { number: 1, content: '$ bundle install' }

Such approach is required to handle cases where data coming from pusher
is not actually a new line. For example output containing dots from
tests needs to be appended:

    $ rake
    ....

Such output could be sent to client in 2 chunks: "$ rake\n.." and "..".
In such situation we would need to send 3 instructions:

  { number: 1, content: '$ rake' }
  { number: 2, content: '..'     }
  { number: 2, content: '..', append: true }

The third instruction can come much later, because tests can take a
while to run, so we can't assume that each line will come in one piece.

The other scenario is \r, for example when showing progress:

    \rDownloading: 10%
    \rDownloading: 50%
    \rDownloading: 100%

Such input should be changed into such instructions:

  { number: 1, content: 'Downloading: 10%' }
  { number: 1, content: 'Downloading: 50%',  replace: true }
  { number: 1, content: 'Downloading: 100%', replace: true }

Travis.Log also supports folds, for example on bundle install, the code
was rewritten to make folds management simpler.
2012-12-04 22:57:57 +01:00
Piotr Sarnacki
3b3de51017 Enable js testing on travis 2012-11-07 17:54:29 +01:00