mirror of
https://github.com/miniflux/v2.git
synced 2025-07-02 16:38:37 +00:00
Add global option POLLING_PARSING_ERROR_LIMIT
This commit is contained in:
parent
b45c1cf327
commit
7c44238bae
6 changed files with 51 additions and 7 deletions
|
@ -761,6 +761,24 @@ func TestDefautSchedulerCountBasedMinInterval(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
func TestPollingParsingErrorLimit(t *testing.T) {
|
||||
os.Clearenv()
|
||||
os.Setenv("POLLING_PARSING_ERROR_LIMIT", "100")
|
||||
|
||||
parser := NewParser()
|
||||
opts, err := parser.ParseEnvironmentVariables()
|
||||
if err != nil {
|
||||
t.Fatalf(`Parsing failure: %v`, err)
|
||||
}
|
||||
|
||||
expected := 100
|
||||
result := opts.PollingParsingErrorLimit()
|
||||
|
||||
if result != expected {
|
||||
t.Fatalf(`Unexpected POLLING_SCHEDULER value, got %v instead of %v`, result, expected)
|
||||
}
|
||||
}
|
||||
|
||||
func TestOAuth2UserCreationWhenUnset(t *testing.T) {
|
||||
os.Clearenv()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue