Antwrap 0.5.4-java → 0.6.0-java

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,34 +0,0 @@
1
- # antwrap
2
- #
3
- # Copyright Caleb Powell 2007
4
- #
5
- # Licensed under the LGPL, see the file COPYING in the distribution
6
- #
7
- require 'test/unit'
8
- require 'fileutils'
9
- require 'java'
10
- require '../lib/convert.rb'
11
-
12
- class TestConvert < Test::Unit::TestCase
13
-
14
- def test_create_symbol
15
- assert_equal(':upload_jar_OHQ', create_symbol('upload-jar-OHQ'))
16
- assert_equal(':upload_jar_OHQ', create_symbol('upload.jar.OHQ'))
17
- assert_equal(':upload_jar_OHQ, :aprop_bar', create_symbol('upload.jar.OHQ, aprop-bar'))
18
- end
19
-
20
-
21
- def test_replace_properties
22
- result = replace_properties("${aprop}", {'aprop' => 'bar'})
23
- assert_equal('bar', result)
24
- result = replace_properties("${aprop}/adir", {'aprop' => 'bar'})
25
- assert_equal('bar/adir', result)
26
- result = replace_properties("${aprop}/${aprop}", {'aprop' => 'bar'})
27
- assert_equal('bar/bar', result)
28
- result = replace_properties("${unrelated}", {'aprop' => 'bar'})
29
- assert_equal('${unrelated}', result)
30
- result = replace_properties("${common.dir}/classes", {'common.dir' => 'bar'})
31
- assert_equal('bar/classes', result)
32
- end
33
-
34
- end