Skip to content

Avoid faking entire package file structure #10

Description

@dhermes

@jgeewax Requested we try to do something better than mock the directory structure, i.e.

https://github.com/dhermes/gcloud-python-bigtable/tree/1221e2cb16289bbd68c544c380872bfa48731a8d/_fake_grpc/grpc

Doing some basic research on StackOverflow, it seems that all import mock solutions require knowledge of the names being imported. One suggestion does a bit better (i.e. in import_mock we could say if name.startswith('grpc')), but requires being put in front of the imports.

/cc @tseaver

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions