mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-01 23:08:43 +01:00
@@ -2,22 +2,9 @@ import os
|
||||
from contextlib import contextmanager
|
||||
from filecmp import dircmp
|
||||
|
||||
from mock import MagicMock
|
||||
|
||||
from dvc.scm import Git
|
||||
|
||||
|
||||
def spy(method_to_decorate):
|
||||
mock = MagicMock()
|
||||
|
||||
def wrapper(self, *args, **kwargs):
|
||||
mock(*args, **kwargs)
|
||||
return method_to_decorate(self, *args, **kwargs)
|
||||
|
||||
wrapper.mock = mock
|
||||
return wrapper
|
||||
|
||||
|
||||
def get_gitignore_content():
|
||||
with open(Git.GITIGNORE, "r") as gitignore:
|
||||
return gitignore.read().splitlines()
|
||||
|
||||
Reference in New Issue
Block a user