Rename DSVReader to DSV

This commit is contained in:
kojix2 2020-12-21 14:25:52 +09:00
parent d6e1840e58
commit fd7b755c79
4 changed files with 6 additions and 6 deletions

View File

@ -2,7 +2,7 @@
require 'unicode_plot'
require 'youplot/version'
require 'youplot/dsv_reader'
require 'youplot/dsv'
require 'youplot/command'
module YouPlot

View File

@ -1,6 +1,6 @@
# frozen_string_literal: true
require_relative 'dsv_reader'
require_relative 'dsv'
require_relative 'command/parser'
# FIXME
@ -54,7 +54,7 @@ module YouPlot
def read_dsv(input)
input = input.dup.force_encoding(options[:encoding]).encode('utf-8') if options[:encoding]
DSVReader.input(input, options[:delimiter], options[:headers], options[:transpose])
DSV.input(input, options[:delimiter], options[:headers], options[:transpose])
end
def create_plot

View File

@ -4,7 +4,7 @@ require 'csv'
module YouPlot
# Read and interpret Delimiter-separated values format file or stream.
module DSVReader
module DSV
module_function
def input(input, delimiter, headers, transpose)

View File

@ -2,9 +2,9 @@
require_relative '../test_helper'
class YouPlotDSVReaderTest < Test::Unit::TestCase
class YouPlotDSVTest < Test::Unit::TestCase
def setup
@m = YouPlot::DSVReader
@m = YouPlot::DSV
end
test :transpose2 do