Sha256: 3b1fbca61d60bdbb1fc5acff489af4ec5dc8623fae4a4ce1fd2024012104318a

Contents?: true

Size: 1.38 KB

Versions: 2

Compression:

Stored size: 1.38 KB

Contents

$:.unshift 'lib'
$LOAD_PATH << File.dirname(__FILE__)

require 'helper'
require 'odesk/api/routers/activities/user'
require 'test/unit'
require 'mocha/test_unit'

class ActivitiesUserTest < Test::Unit::TestCase
  include TestHelper
  
  def test_get_list
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.get_list('company', 'team', 'user')
  end
  
  def test_get_full_list
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.get_full_list('company', 'team', 'user')
  end
  
  def test_get_specific_list
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.get_specific_list('company', 'team', 'user', 'code')
  end
    
  def test_add_activity
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.add_activity('company', 'team', 'user', {})
  end
    
  def test_update_activities
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.update_activities('company', 'team', 'user', 'code', {})
  end
    
  def test_delete_activities
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.delete_activities('company', 'team', 'user', 'code')
  end
    
  def test_delete_all_activities
    api = Odesk::Api::Routers::Activities::User.new(get_client_mock)
    assert api.delete_all_activities('company', 'team', 'user')
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
odesk-api-0.1.1 test/test_activities_user.rb
odesk-api-0.1.0 test/test_activities_user.rb