diff options
| author | Ondřej Surý <ondrej@sury.org> | 2011-05-04 15:46:02 +0200 | 
|---|---|---|
| committer | Ondřej Surý <ondrej@sury.org> | 2011-05-23 11:04:16 +0200 | 
| commit | fd089e27d7260cee1c7ca449c41cdd0341ebc6cb (patch) | |
| tree | 3f3f9f49b86ecec97b875de7f407e7d0f2427975 /src/pkg/xml/xml_test.go | |
| parent | 1f2ed67937cacb19b0b7e54ea3f5866ca34842a0 (diff) | |
| download | golang-fd089e27d7260cee1c7ca449c41cdd0341ebc6cb.tar.gz | |
Imported Upstream version 2011.04.27
Diffstat (limited to 'src/pkg/xml/xml_test.go')
| -rw-r--r-- | src/pkg/xml/xml_test.go | 81 | 
1 files changed, 38 insertions, 43 deletions
| diff --git a/src/pkg/xml/xml_test.go b/src/pkg/xml/xml_test.go index 4e51cd53a..a99c1919e 100644 --- a/src/pkg/xml/xml_test.go +++ b/src/pkg/xml/xml_test.go @@ -329,50 +329,46 @@ func TestSyntax(t *testing.T) {  }  type allScalars struct { -	True1     bool -	True2     bool -	False1    bool -	False2    bool -	Int       int -	Int8      int8 -	Int16     int16 -	Int32     int32 -	Int64     int64 -	Uint      int -	Uint8     uint8 -	Uint16    uint16 -	Uint32    uint32 -	Uint64    uint64 -	Uintptr   uintptr -	Float32   float32 -	Float64   float64 -	String    string -	PtrString *string +	True1   bool +	True2   bool +	False1  bool +	False2  bool +	Int     int +	Int8    int8 +	Int16   int16 +	Int32   int32 +	Int64   int64 +	Uint    int +	Uint8   uint8 +	Uint16  uint16 +	Uint32  uint32 +	Uint64  uint64 +	Uintptr uintptr +	Float32 float32 +	Float64 float64 +	String  string  }  var all = allScalars{ -	True1:     true, -	True2:     true, -	False1:    false, -	False2:    false, -	Int:       1, -	Int8:      -2, -	Int16:     3, -	Int32:     -4, -	Int64:     5, -	Uint:      6, -	Uint8:     7, -	Uint16:    8, -	Uint32:    9, -	Uint64:    10, -	Uintptr:   11, -	Float32:   13.0, -	Float64:   14.0, -	String:    "15", -	PtrString: &sixteen, -} - -var sixteen = "16" +	True1:   true, +	True2:   true, +	False1:  false, +	False2:  false, +	Int:     1, +	Int8:    -2, +	Int16:   3, +	Int32:   -4, +	Int64:   5, +	Uint:    6, +	Uint8:   7, +	Uint16:  8, +	Uint32:  9, +	Uint64:  10, +	Uintptr: 11, +	Float32: 13.0, +	Float64: 14.0, +	String:  "15", +}  const testScalarsInput = `<allscalars>  	<true1>true</true1> @@ -394,7 +390,6 @@ const testScalarsInput = `<allscalars>  	<float32>13.0</float32>  	<float64>14.0</float64>  	<string>15</string> -	<ptrstring>16</ptrstring>  </allscalars>`  func TestAllScalars(t *testing.T) { @@ -406,7 +401,7 @@ func TestAllScalars(t *testing.T) {  		t.Fatal(err)  	}  	if !reflect.DeepEqual(a, all) { -		t.Errorf("have %+v want %+v", a, all) +		t.Errorf("expected %+v got %+v", all, a)  	}  } | 
