Skip to content

How to skip constants with tapioca gem GEM? #2183

Open
@ivy

Description

Hi! 👋 I ran into a problem where I wanted to run tapioca gem activesupport but I was getting errors from Sorbet because ActiveSupport::TestCase extends from Minitest which is not a dependency in my project. I didn't want to add it so I worked around it by making a hack with the following:

# sorbet/tapioca/require.rb
require 'active_support'
ActiveSupport.const_set(:TestCase, nil)

This feels icky and I'd have preferred to have something like:

# sorbet/tapioca/config.yml

gem:
  skip_constant:
    - "ActiveSupport::TestCase"

That doesn't appear to be an option though! Am I misunderstanding how tapioca dsl is intended to be used? Please me know if I missed something in the docs! Thanks a bunch! 😅

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions