Sha256: d7ef5e6e256b7f308ff14173f4db046a45e57eaa5b79b84c3b36ecafe9a2a6c0
Contents?: true
Size: 810 Bytes
Versions: 34
Compression:
Stored size: 810 Bytes
Contents
require_relative '../../test_helper' require_relative '../../resource_test' module MeducationSDK class Badges::BadgeTest < ResourceTest def self.test_badge(klass) define_method :klass do klass end class_eval do def test_issue_or_update_progress_calls_loquor user_id = 12 url = "#{klass.path}/issue_or_update_progress" Loquor.expects(:put).with(url, user_id: user_id) klass.issue_or_update_progress(user_id) end def test_user_calls_sdk badge = klass.new(user_id: 3) MeducationSDK::User.expects(:find).with(3) badge.user end def test_ruby_gets_called return unless ENV["INTEGRATION"] klass.issue_or_update_progress(2) end end end end end
Version data entries
34 entries across 34 versions & 1 rubygems