From d994bf77349cdcb8a2c75d0475105a8dc87afa67 Mon Sep 17 00:00:00 2001
From: Amandine PERRIN <amandine.perrin@pasteur.fr>
Date: Tue, 1 Dec 2020 10:24:29 +0100
Subject: [PATCH] remove obsolete function

---
 .../annotate_module/general_format_functions.py  | 16 ----------------
 test/test_unit/test_annotate/test_format_func.py | 11 -----------
 2 files changed, 27 deletions(-)

diff --git a/PanACoTA/annotate_module/general_format_functions.py b/PanACoTA/annotate_module/general_format_functions.py
index 0532b0a5..1659c6cb 100644
--- a/PanACoTA/annotate_module/general_format_functions.py
+++ b/PanACoTA/annotate_module/general_format_functions.py
@@ -281,19 +281,3 @@ def write_header(lstline, outfile):
     size = int(end) - int(start) + 1
     towrite = " ".join([name, str(size), gene_name, info])
     outfile.write(">" + towrite + "\n")
-
-
-def get_contig_name(genome, cont_num):
-    """
-    From a genome name and a contig number, write the header corresponding to this contig
-    (for 'Replicons' files)
-
-    Parameters
-    ----------
-    genome : str
-        genome name
-    cont_num : int
-        contig number
-    """
-    return ">{}.{}".format(genome, str(cont_num).zfill(4))
-
diff --git a/test/test_unit/test_annotate/test_format_func.py b/test/test_unit/test_annotate/test_format_func.py
index 7f652f5e..9a0f779c 100755
--- a/test/test_unit/test_annotate/test_format_func.py
+++ b/test/test_unit/test_annotate/test_format_func.py
@@ -97,17 +97,6 @@ def test_write_gene():
     assert tutil.compare_order_content(exp_file, lstfile)
 
 
-def test_contig_name():
-    """
-    test that when we give a genome name and a contig number, it returns the expected fasta header
-    for Replicon files (no gene number)
-    """
-    genome = "ESCO.1218.00005"
-    cont_num = 30
-    head_line = ffunc.get_contig_name(genome, cont_num)
-    assert head_line == ">ESCO.1218.00005.0030"
-
-
 def test_write_header_gene():
     """
     From a given line of lstinfo file, giving info for a gene (start, end, gene name,
-- 
GitLab