diff --git a/fixtures/quoted.env b/fixtures/quoted.env index cc6376a..7958933 100644 --- a/fixtures/quoted.env +++ b/fixtures/quoted.env @@ -7,3 +7,13 @@ OPTION_F="2" OPTION_G="" OPTION_H="\n" OPTION_I = "echo 'asd'" +OPTION_J='line 1 +line 2' +OPTION_K='line one +this is \'quoted\' +one more line' +OPTION_L="line 1 +line 2" +OPTION_M="line one +this is \"quoted\" +one more line" diff --git a/godotenv_test.go b/godotenv_test.go index 0045a8c..f5820b6 100644 --- a/godotenv_test.go +++ b/godotenv_test.go @@ -189,6 +189,10 @@ func TestLoadQuotedEnv(t *testing.T) { "OPTION_G": "", "OPTION_H": "\n", "OPTION_I": "echo 'asd'", + "OPTION_J": "line 1\nline 2", + "OPTION_K": "line one\nthis is \\'quoted\\'\none more line", + "OPTION_L": "line 1\nline 2", + "OPTION_M": "line one\nthis is \"quoted\"\none more line", } loadEnvAndCompareValues(t, Load, envFileName, expectedValues, noopPresets)