Skip to content

Commit

Permalink
Merge pull request #26 from krakendio/upgrade_sprig
Browse files Browse the repository at this point in the history
avoid using deprecated functions
  • Loading branch information
kpacha authored Jan 24, 2023
2 parents f434a55 + b60cbdc commit a16aca6
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions template_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package flexibleconfig

import (
"fmt"
"io/ioutil"
"os"
"text/template"

Expand All @@ -11,7 +10,7 @@ import (
)

func ExampleTemplateParser_marshal() {
tmpfile, err := ioutil.TempFile("", "KrakenD_parsed_config_template_0_")
tmpfile, err := os.CreateTemp("", "KrakenD_parsed_config_template_0_")
if err != nil {
fmt.Println(err.Error())
return
Expand Down Expand Up @@ -119,7 +118,7 @@ func ExampleTemplateParser_marshal() {
}

func ExampleTemplateParser_include() {
tmpfile, err := ioutil.TempFile("", "KrakenD_parsed_config_template_1_")
tmpfile, err := os.CreateTemp("", "KrakenD_parsed_config_template_1_")
if err != nil {
fmt.Println(err.Error())
return
Expand All @@ -135,7 +134,7 @@ func ExampleTemplateParser_include() {
return
}

includeTmpfile, err := ioutil.TempFile("", "KrakenD_parsed_config_template_2_")
includeTmpfile, err := os.CreateTemp("", "KrakenD_parsed_config_template_2_")
if err != nil {
fmt.Println(err.Error())
return
Expand Down

0 comments on commit a16aca6

Please sign in to comment.