Skip to content

Commit

Permalink
Remove unnecessary test
Browse files Browse the repository at this point in the history
  • Loading branch information
yutaro-oguri committed Oct 19, 2023
1 parent b64d2c1 commit 6dd28bf
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
2 changes: 1 addition & 1 deletion gokart/file_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ def dump(self, obj, file):
def make_file_processor(file_path: str, store_index_in_feather: bool) -> FileProcessor:
extension2processor = {
'.txt': TextFileProcessor(),
'.ini': TextFileProcessor(),
'.csv': CsvFileProcessor(sep=','),
'.tsv': CsvFileProcessor(sep='\t'),
'.pkl': PickleFileProcessor(),
Expand All @@ -280,7 +281,6 @@ def make_file_processor(file_path: str, store_index_in_feather: bool) -> FilePro
'.feather': FeatherFileProcessor(store_index_in_feather=store_index_in_feather),
'.png': BinaryFileProcessor(),
'.jpg': BinaryFileProcessor(),
'.ini': TextFileProcessor(),
}

extension = os.path.splitext(file_path)[1]
Expand Down
14 changes: 0 additions & 14 deletions test/test_target.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import boto3
import numpy as np
import pandas as pd
from luigi.configuration.cfg_parser import LuigiConfigParser
from matplotlib import pyplot
from moto import mock_s3

Expand Down Expand Up @@ -128,19 +127,6 @@ def test_save_and_load_feather_without_store_index_in_feather(self):

pd.testing.assert_frame_equal(loaded, obj)

def test_save_and_load_config_ini_file(self):
obj = LuigiConfigParser()
obj['common'] = {'a': '1', 'b': 'yes', 'c': 2}
obj['example'] = {}
obj['example']['d'] = 'foo'
obj['example']['e'] = 'true'
file_path = os.path.join(_get_temporary_directory(), 'test.ini')

target = make_target(file_path=file_path, unique_id=None)
target.dump(obj)
loaded = target.load()
self.assertEqual(loaded, [str(obj)], msg='should save an object as List[str].')

def test_last_modified_time(self):
obj = pd.DataFrame(dict(a=[1, 2], b=[3, 4]))
file_path = os.path.join(_get_temporary_directory(), 'test.csv')
Expand Down

0 comments on commit 6dd28bf

Please sign in to comment.