@@ -798,10 +798,10 @@ class GitRepositoryTests: XCTestCase {
798
798
799
799
let customRemoteWithoutPathExtension = ( customRemote as NSString ) . deletingPathExtension
800
800
XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemote) ) ) )
801
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
802
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemoteWithoutPathExtension) ) ) )
803
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
804
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( ( customRemote as NSString ) . deletingPathExtension + " / " ) ) ) )
801
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
802
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemoteWithoutPathExtension) ) ) )
803
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
804
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( ( customRemote as NSString ) . deletingPathExtension + " / " ) ) ) )
805
805
806
806
// The following ensure that are actually checking the remote's origin.
807
807
XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: AbsolutePath ( validating: " / " ) ) ) )
@@ -846,12 +846,12 @@ class GitRepositoryTests: XCTestCase {
846
846
let customRemotePathWithoutPathExtension = ( customRemotePath as NSString ) . deletingPathExtension
847
847
XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: customRemote) ) )
848
848
XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemotePath) ) ) )
849
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
850
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: try AbsolutePath ( validating: customRemotePathWithoutPathExtension) ) ) )
851
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemotePathWithoutPathExtension) ) ) )
852
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
853
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: try AbsolutePath ( validating: customRemotePathWithoutPathExtension + " / " ) ) ) )
854
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( ( customRemotePath as NSString ) . deletingPathExtension + " / " ) ) ) )
849
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
850
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: try AbsolutePath ( validating: customRemotePathWithoutPathExtension) ) ) )
851
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemotePathWithoutPathExtension) ) ) )
852
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
853
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: try AbsolutePath ( validating: customRemotePathWithoutPathExtension + " / " ) ) ) )
854
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( ( customRemotePath as NSString ) . deletingPathExtension + " / " ) ) ) )
855
855
856
856
// The following ensure that are actually checking the remote's origin.
857
857
XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: AbsolutePath ( validating: " / " ) ) ) )
@@ -892,10 +892,10 @@ class GitRepositoryTests: XCTestCase {
892
892
XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir) )
893
893
894
894
XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( customRemote) ) ) )
895
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
896
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( " https://mycustomdomain/some-package " ) ) ) )
897
- // We consider the directory valid even if the remote does not have the same path extension - in this case we expected '.git'.
898
- XCTAssertTrue ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( " https://mycustomdomain/some-package/ " ) ) ) )
895
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
896
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( " https://mycustomdomain/some-package " ) ) ) )
897
+ // We consider the directory invalid if the remote does not have the same path extension - in this case we expected '.git'.
898
+ XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( url: SourceControlURL ( " https://mycustomdomain/some-package/ " ) ) ) )
899
899
900
900
// The following ensure that are actually checking the remote's origin.
901
901
XCTAssertFalse ( try repositoryManager. isValidDirectory ( packageDir, for: RepositorySpecifier ( path: AbsolutePath ( validating: " / " ) ) ) )
0 commit comments