refactor(t228): remove Python ERP connector
This commit is contained in:
@@ -42,16 +42,6 @@ func TestLoadUsesSafeDefaults(t *testing.T) {
|
||||
if cfg.ShutdownTimeout > 30*time.Second {
|
||||
t.Fatalf("ShutdownTimeout = %s", cfg.ShutdownTimeout)
|
||||
}
|
||||
if cfg.ERPConnectorURL != "http://127.0.0.1:8091" ||
|
||||
cfg.ERPConnectorAPIKey != "" ||
|
||||
cfg.ERPConnectorTimeout != 90*time.Second {
|
||||
t.Fatalf(
|
||||
"ERP connector defaults = %q / %q / %s",
|
||||
cfg.ERPConnectorURL,
|
||||
cfg.ERPConnectorAPIKey,
|
||||
cfg.ERPConnectorTimeout,
|
||||
)
|
||||
}
|
||||
if cfg.ShunyunbaoURL != "https://www.shunyunbaoerp.com" ||
|
||||
cfg.ShunyunbaoUsername != "" || cfg.ShunyunbaoPassword != "" ||
|
||||
cfg.ShunyunbaoTimeout != 30*time.Second {
|
||||
@@ -75,8 +65,6 @@ func TestLoadAcceptsExplicitConfiguration(t *testing.T) {
|
||||
ClaimLeaseEnvironment: "15m",
|
||||
RunningLeaseEnvironment: "45m",
|
||||
ReadinessTTLEnvironment: "3m",
|
||||
ERPConnectorURLEnvironment: "http://localhost:18091",
|
||||
ERPConnectorAPIKeyEnvironment: "12345678901234567890123456789012",
|
||||
ShunyunbaoURLEnvironment: "https://erp.example.test:8443",
|
||||
ShunyunbaoUsernameEnvironment: "service-user",
|
||||
ShunyunbaoPasswordEnvironment: " pass with spaces ",
|
||||
@@ -114,14 +102,6 @@ func TestLoadAcceptsExplicitConfiguration(t *testing.T) {
|
||||
cfg.ReadinessTTL,
|
||||
)
|
||||
}
|
||||
if cfg.ERPConnectorURL != values[ERPConnectorURLEnvironment] ||
|
||||
cfg.ERPConnectorAPIKey != values[ERPConnectorAPIKeyEnvironment] {
|
||||
t.Fatalf(
|
||||
"ERP connector = %q / %q",
|
||||
cfg.ERPConnectorURL,
|
||||
cfg.ERPConnectorAPIKey,
|
||||
)
|
||||
}
|
||||
if cfg.ShunyunbaoURL != values[ShunyunbaoURLEnvironment] ||
|
||||
cfg.ShunyunbaoUsername != values[ShunyunbaoUsernameEnvironment] ||
|
||||
cfg.ShunyunbaoPassword != values[ShunyunbaoPasswordEnvironment] {
|
||||
@@ -134,24 +114,6 @@ func TestLoadRejectsUnsafeOrInvalidValues(t *testing.T) {
|
||||
name string
|
||||
values map[string]string
|
||||
}{
|
||||
{
|
||||
name: "non-loopback ERP connector",
|
||||
values: map[string]string{
|
||||
ERPConnectorURLEnvironment: "http://192.0.2.10:8091",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "ERP connector path",
|
||||
values: map[string]string{
|
||||
ERPConnectorURLEnvironment: "http://127.0.0.1:8091/private",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "short ERP connector key",
|
||||
values: map[string]string{
|
||||
ERPConnectorAPIKeyEnvironment: "short",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "non HTTPS shunyunbao URL",
|
||||
values: map[string]string{
|
||||
|
||||
Reference in New Issue
Block a user