mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
Fix test
This commit is contained in:
parent
58e5f917a4
commit
1d1638c27e
2 changed files with 3 additions and 1 deletions
|
|
@ -75,7 +75,7 @@ public class NoteInterpreterLoader {
|
|||
}
|
||||
|
||||
private String getInterpreterGroupKey(InterpreterSetting setting) {
|
||||
if (setting.getOption().isPerNoteSession()) {
|
||||
if (!setting.getOption().isPerNoteSession()) {
|
||||
return SHARED_SESSION;
|
||||
} else {
|
||||
return noteId;
|
||||
|
|
|
|||
|
|
@ -101,10 +101,12 @@ public class NoteInterpreterLoaderTest {
|
|||
NoteInterpreterLoader loaderA = new NoteInterpreterLoader(factory);
|
||||
loaderA.setNoteId("noteA");
|
||||
loaderA.setInterpreters(factory.getDefaultInterpreterSettingList());
|
||||
loaderA.getInterpreterSettings().get(0).getOption().setPerNoteSession(true);
|
||||
|
||||
NoteInterpreterLoader loaderB = new NoteInterpreterLoader(factory);
|
||||
loaderB.setNoteId("noteB");
|
||||
loaderB.setInterpreters(factory.getDefaultInterpreterSettingList());
|
||||
loaderB.getInterpreterSettings().get(0).getOption().setPerNoteSession(true);
|
||||
|
||||
// interpreters are not created before accessing it
|
||||
assertNull(loaderA.getInterpreterSettings().get(0).getInterpreterGroup().get("noteA"));
|
||||
|
|
|
|||
Loading…
Reference in a new issue