@@ -356,7 +356,7 @@ func (s *ProcessorSuite) TestIsModel() {
356
356
Ptr *Bar
357
357
NoPtr Bar
358
358
Struct Struct
359
- }
359
+ }
360
360
`
361
361
pkg := s .processFixture (src )
362
362
m := findModel (pkg , "Foo" )
@@ -401,7 +401,7 @@ func (s *ProcessorSuite) TestIsEmbedded() {
401
401
C struct {
402
402
D int
403
403
}
404
- }
404
+ }
405
405
`
406
406
pkg := s .processFixture (src )
407
407
m := findModel (pkg , "Foo" )
@@ -457,6 +457,41 @@ func TestRemoveGoPath(t *testing.T) {
457
457
},
458
458
'/' ,
459
459
},
460
+ {
461
+ "/go/src/foo/go/src/fixtures.AliasString" ,
462
+ "foo/go/src/fixtures.AliasString" ,
463
+ []string {
464
+ "/go" ,
465
+ },
466
+ '/' ,
467
+ },
468
+ {
469
+ "/home/workspace/gopath/src/foo/bar/vendor/gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
470
+ "gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
471
+ []string {
472
+ "/home/foo/go" ,
473
+ "/home/workspace/gopath" ,
474
+ },
475
+ '/' ,
476
+ },
477
+ {
478
+ "/home/vendor/workspace/gopath/src/gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
479
+ "gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
480
+ []string {
481
+ "/home/foo/go" ,
482
+ "/home/vendor/workspace/gopath" ,
483
+ },
484
+ '/' ,
485
+ },
486
+ {
487
+ "/home/vendor/workspace/gopath/src/vendor/gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
488
+ "gopkg.in/src-d/go-kallax.v1/tests/fixtures.AliasString" ,
489
+ []string {
490
+ "/home/foo/go" ,
491
+ "/home/vendor/workspace/gopath" ,
492
+ },
493
+ '/' ,
494
+ },
460
495
}
461
496
462
497
for _ , c := range cases {
0 commit comments