Skip to content

Commit

Permalink
[HWORKS-789] Fix git tests (#1584) (#1413)
Browse files Browse the repository at this point in the history
* Fix git tests

* Fix
  • Loading branch information
gibchikafa authored Oct 13, 2023
1 parent 520fecc commit 95ba585
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions hopsworks-IT/src/test/ruby/spec/git_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,14 @@
end
end
describe "Perform operations on the cloned repositories" do
before(:all) do
setVar("enable_read_only_git_repositories", "false")
create_session(@project[:username], "Pass123")
end
after(:all) do
setVar("enable_read_only_git_repositories", "true")
create_session(@project[:username], "Pass123")
end
after :each do
get_project_git_repositories(@project[:id])
if json_body[:count] > 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,8 +227,8 @@ private GitRepository finalizeSuccessfulExecution(GitOpExecution execution,
}
if (executedCommandConfig.getCommandType() == GitCommandType.ADD_REMOTE ||
executedCommandConfig.getCommandType() == GitCommandType.DELETE_REMOTE) {
//Update the remotes which are in the execution final message
String remotesJson = execution.getCommandResultMessage();
//Update the remotes which are in the stateDTO final message
String remotesJson = stateDTO.getMessage();
if (!Strings.isNullOrEmpty(remotesJson)) {
gitRepositoryRemotesFacade.updateRepositoryRemotes(gitCommandOperationUtil.convertToRemote(repository,
remotesJson), repository);
Expand Down

0 comments on commit 95ba585

Please sign in to comment.