use of com.searchcode.app.model.RepoResult in project searchcode-server by boyter.
the class RepoTest method testRepoSaveGetCacheBug.
public void testRepoSaveGetCacheBug() {
this.repo.saveRepo(new RepoResult(-1, "myname", "git", "myurl", "username", "password", "mysource", "mybranch", "{}"));
for (int i = 0; i < 200; i++) {
assertThat(repo.getRepoByName("myname")).isNotNull();
}
this.repo.deleteRepoByName("myname");
}
use of com.searchcode.app.model.RepoResult in project searchcode-server by boyter.
the class RepoTest method testGetRepoByNameUsingNull.
public void testGetRepoByNameUsingNull() {
RepoResult repoResult = this.repo.getRepoByName(null);
assertThat(repoResult).isNull();
}
use of com.searchcode.app.model.RepoResult in project searchcode-server by boyter.
the class RepoTest method testGetAllRepo.
public void testGetAllRepo() {
this.repo.saveRepo(new RepoResult(-1, "myname", "git", "myurl", "username", "password", "mysource", "mybranch", "{}"));
assertThat(this.repo.getAllRepo().size()).isGreaterThanOrEqualTo(1);
this.repo.deleteRepoByName("myname");
}
use of com.searchcode.app.model.RepoResult in project searchcode-server by boyter.
the class RepoTest method testRepoByUrlMemoryLeak.
public void testRepoByUrlMemoryLeak() {
for (int i = 0; i < 200; i++) {
this.repo.saveRepo(new RepoResult(-1, "myname", "git", "myurl", "username", "password", "mysource", "mybranch", "{}"));
assertThat(this.repo.getRepoByUrl("myurl")).isNotNull();
this.repo.deleteRepoByName("myname");
}
}
use of com.searchcode.app.model.RepoResult in project searchcode-server by boyter.
the class RepoTest method testRepoByUrl.
public void testRepoByUrl() {
this.repo.saveRepo(new RepoResult(-1, "myname", "git", "myurl", "username", "password", "mysource", "mybranch", "{}"));
assertThat(this.repo.getRepoByUrl("myurl")).isNotNull();
this.repo.deleteRepoByName("myname");
}
Aggregations