Skip to content
Snippets Groups Projects
Verified Commit 58a57987 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

chore: manage flake

parent 9a8c01a7
No related branches found
No related tags found
No related merge requests found
...@@ -4,8 +4,10 @@ ...@@ -4,8 +4,10 @@
package utils package utils
import ( import (
"fmt"
"os" "os"
"path/filepath" "path/filepath"
"runtime"
"testing" "testing"
) )
...@@ -21,11 +23,16 @@ func TestMaskCodeBlocks(t *testing.T) { ...@@ -21,11 +23,16 @@ func TestMaskCodeBlocks(t *testing.T) {
for _, table := range tables { for _, table := range tables {
p, _ := os.Getwd() //p, _ := os.Getwd()
_, p, _, _ := runtime.Caller(0)
// p = filepath.Dir(p) // go to parent directory // p = filepath.Dir(p) // go to parent directory
p = filepath.Dir(p) // go to parent directory p = filepath.Dir(p) // go to parent directory
p = filepath.Dir(p) // go to parent directory
p = filepath.Dir(p) // go to parent directory
p = filepath.Join(p, table.input) p = filepath.Join(p, table.input)
fmt.Println(p)
code, err := os.ReadFile(p) code, err := os.ReadFile(p)
if err != nil { if err != nil {
t.Errorf("Error reading file %s", table.input) t.Errorf("Error reading file %s", table.input)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment