View Javadoc

1   /*
2    * ------------------------------------------------------------------------------
3    * Hermes FTP Server
4    * Copyright (c) 2005-2007 Lars Behnke
5    * ------------------------------------------------------------------------------
6    * 
7    * This file is part of Hermes FTP Server.
8    * 
9    * Hermes FTP Server is free software; you can redistribute it and/or modify
10   * it under the terms of the GNU General Public License as published by
11   * the Free Software Foundation; either version 2 of the License, or
12   * (at your option) any later version.
13   * 
14   * Hermes FTP Server is distributed in the hope that it will be useful,
15   * but WITHOUT ANY WARRANTY; without even the implied warranty of
16   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17   * GNU General Public License for more details.
18   * 
19   * You should have received a copy of the GNU General Public License
20   * along with Hermes FTP Server; if not, write to the Free Software
21   * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
22   * ------------------------------------------------------------------------------
23   */
24  package net.sf.hermesftp.server.impl;
25  
26  import java.io.IOException;
27  
28  import org.junit.Test;
29  import static org.junit.Assert.*;
30  
31  // CHECKSTYLE:OFF
32  
33  /***
34   * Unit tests that cover RFC 2389 functionality.
35   * 
36   * @author Lars Behnke
37   */
38  public class ServerRFC2389Test extends AbstractClientServerTestCase {
39  
40      /***
41       * Test case: Feature negotiation.
42       */
43      @Test public void testFeatureNegociation() {
44          try {
45              String str;
46              str = getClient().sendAndReceive("FEAT");
47              assertTrue(str.indexOf("UTF8") > 0);
48  
49              // TODO test RFC 2389 commands
50  
51          } catch (IOException e) {
52              fail(e.toString());
53          }
54      }
55  
56  }
57  
58  // CHECKSTYLE:ON
59