Sha256: bef799af91a72e924fe3c1189fdbb9f1733701bfa6a37fda9e91b0e33ccec9ad

Contents?: true

Size: 606 Bytes

Versions: 4

Compression:

Stored size: 606 Bytes

Contents

module Lanes

    module API

        class DummyUser
            def can_read?(*args)
                true
            end
            def can_write?(*args)
                true
            end
            def can_delete?(*args)
                true
            end
        end

        class AuthenticationProvider
            USER = DummyUser.new

            def initialize(session:nil, params:nil, request_type: type)
            end

            def current_user
                USER
            end

            def wrap_request(model)
                yield
            end

        end
    end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
lanes-0.1.2 lib/lanes/api/null_authentication_provider.rb
lanes-0.1.0 lib/lanes/api/null_authentication_provider.rb
lanes-0.0.8 lib/lanes/api/null_authentication_provider.rb
lanes-0.0.5 lib/lanes/api/null_authentication_provider.rb