-
-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add new image files for end-to-end testing of burst and upgrade…
… low-quality scenarios
- Loading branch information
Showing
66 changed files
with
837 additions
and
3 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+2.94 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST001_COVER.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+2.93 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST002.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+3.06 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST003.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+2.99 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST004.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+3.04 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST005.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+3.03 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST006.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+3.08 MB
internal/e2eTests/tests/DATA/bursts/phone/IMG_20231014_183246_BURST007.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#!/bin/bash | ||
|
||
# Define the source and destination directories | ||
SOURCE_DIR="high_jpg" | ||
DEST_DIR="low" | ||
|
||
# Create the destination directory if it doesn't exist | ||
mkdir -p "$DEST_DIR" | ||
|
||
# Loop through all image files in the source directory | ||
for IMAGE in "$SOURCE_DIR"/*; do | ||
# Get the base name and extension of the image file | ||
BASENAME=$(basename "$IMAGE") | ||
EXTENSION="${BASENAME##*.}" | ||
NAME="${BASENAME%.*}" | ||
|
||
# Recompress the image with very bad quality and save it to the destination directory | ||
convert "$IMAGE" -quality 10 "$DEST_DIR/$NAME".jpg | ||
done | ||
|
||
echo "Recompression complete. Recompressed images are saved in the 'low' subfolder." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#!/bin/bash | ||
# file.sh | ||
|
||
# Define the input and output folders | ||
SOURCE_DIR="high" | ||
DEST_DIR="high_jpg" | ||
|
||
|
||
# Create the output folder if it doesn't exist | ||
mkdir -p "$DEST_DIR" | ||
|
||
# Iterate through all files in the input folder | ||
for IMAGE in "$SOURCE_DIR"/*; do | ||
BASENAME=$(basename "$IMAGE") | ||
EXTENSION="${BASENAME##*.}" | ||
NAME="${BASENAME%.*}" | ||
convert "$IMAGE" "$DEST_DIR/$NAME".jpg | ||
done | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#!/bin/bash | ||
# file.sh | ||
|
||
# Define the input and output folders | ||
SOURCE_DIR="high" | ||
DEST_DIR="high_heic" | ||
|
||
|
||
# Create the output folder if it doesn't exist | ||
mkdir -p "$DEST_DIR" | ||
|
||
# Iterate through all files in the input folder | ||
for IMAGE in "$SOURCE_DIR"/*; do | ||
BASENAME=$(basename "$IMAGE") | ||
EXTENSION="${BASENAME##*.}" | ||
NAME="${BASENAME%.*}" | ||
convert "$IMAGE" "$DEST_DIR/$NAME".HEIC | ||
done | ||
|
Binary file added
BIN
+4.54 MB
internal/e2eTests/tests/DATA/groups/PXL_20250308_131917471.RAW-01.MP.COVER.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+13.8 MB
internal/e2eTests/tests/DATA/groups/PXL_20250308_131917471.RAW-02.ORIGINAL.dng
Binary file not shown.
Binary file added
BIN
+32.6 KB
internal/e2eTests/tests/DATA/groups/PinClipart.com_gopher-clipart_4000224.HEIC
Binary file not shown.
Binary file added
BIN
+66.8 KB
internal/e2eTests/tests/DATA/groups/PinClipart.com_gopher-clipart_4000224.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+188 KB
internal/e2eTests/tests/DATA/high/PinClipart.com_gopher-clipart_4000224.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+223 KB
internal/e2eTests/tests/DATA/high/PinClipart.com_gopher-clipart_4000227.png
Oops, something went wrong.
Binary file added
BIN
+251 KB
internal/e2eTests/tests/DATA/high/PinClipart.com_gopher-clipart_4000243.png
Oops, something went wrong.
Binary file added
BIN
+118 KB
internal/e2eTests/tests/DATA/high/PinClipart.com_gopher-clipart_4860947.png
Oops, something went wrong.
Binary file added
BIN
+154 KB
internal/e2eTests/tests/DATA/high/PinClipart.com_st-clipart_4010097.png
Oops, something went wrong.
Binary file added
BIN
+32.6 KB
internal/e2eTests/tests/DATA/high_heic/PinClipart.com_gopher-clipart_4000224.HEIC
Binary file not shown.
Binary file added
BIN
+33.4 KB
internal/e2eTests/tests/DATA/high_heic/PinClipart.com_gopher-clipart_4000227.HEIC
Binary file not shown.
Binary file added
BIN
+34 KB
internal/e2eTests/tests/DATA/high_heic/PinClipart.com_gopher-clipart_4000243.HEIC
Binary file not shown.
Binary file added
BIN
+26 KB
internal/e2eTests/tests/DATA/high_heic/PinClipart.com_gopher-clipart_4860947.HEIC
Binary file not shown.
Binary file added
BIN
+47.5 KB
internal/e2eTests/tests/DATA/high_heic/PinClipart.com_st-clipart_4010097.HEIC
Binary file not shown.
Binary file added
BIN
+66.8 KB
internal/e2eTests/tests/DATA/high_jpg/PinClipart.com_gopher-clipart_4000224.jpg
Oops, something went wrong.
Binary file added
BIN
+67.1 KB
internal/e2eTests/tests/DATA/high_jpg/PinClipart.com_gopher-clipart_4000227.jpg
Oops, something went wrong.
Binary file added
BIN
+72.6 KB
internal/e2eTests/tests/DATA/high_jpg/PinClipart.com_gopher-clipart_4000243.jpg
Oops, something went wrong.
Binary file added
BIN
+55.3 KB
internal/e2eTests/tests/DATA/high_jpg/PinClipart.com_gopher-clipart_4860947.jpg
Oops, something went wrong.
Binary file added
BIN
+85.4 KB
internal/e2eTests/tests/DATA/high_jpg/PinClipart.com_st-clipart_4010097.jpg
Oops, something went wrong.
Oops, something went wrong.
Binary file added
BIN
+31 KB
...al/e2eTests/tests/DATA/low_duplicates/PinClipart.com_gopher-clipart_4860947.jpg
Oops, something went wrong.
Binary file added
BIN
+47.1 KB
internal/e2eTests/tests/DATA/low_duplicates/PinClipart.com_st-clipart_4010097.jpg
Oops, something went wrong.
Binary file added
BIN
+35.5 KB
internal/e2eTests/tests/DATA/low_jpg/PinClipart.com_gopher-clipart_4000224.jpg
Oops, something went wrong.
Binary file added
BIN
+37.4 KB
internal/e2eTests/tests/DATA/low_jpg/PinClipart.com_gopher-clipart_4000227.jpg
Oops, something went wrong.
Binary file added
BIN
+39.3 KB
internal/e2eTests/tests/DATA/low_jpg/PinClipart.com_gopher-clipart_4000243.jpg
Oops, something went wrong.
Binary file added
BIN
+31 KB
internal/e2eTests/tests/DATA/low_jpg/PinClipart.com_gopher-clipart_4860947.jpg
Oops, something went wrong.
Binary file added
BIN
+47.1 KB
internal/e2eTests/tests/DATA/low_jpg/PinClipart.com_st-clipart_4010097.jpg
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Binary file added
BIN
+82.3 KB
...eTests/tests/DATA/low_other_names/golang-emblem-blue-gopher-vector-27827794.jpg
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/bash | ||
|
||
# Check if the correct number of arguments is provided | ||
if [ "$#" -ne 1 ]; then | ||
echo "Usage: $0 <timestamp>" | ||
exit 1 | ||
fi | ||
|
||
# Get the timestamp from the argument | ||
timestamp="$1" | ||
|
||
# Find all files in subfolders (excluding the current directory) and set their modified time | ||
find . -mindepth 2 -type f -exec touch -d "$timestamp" {} \; | ||
|
||
echo "All files in subfolders have been set to the modified time: $timestamp" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/bin/bash | ||
# add_text_to_images.sh | ||
|
||
# Check if the correct number of arguments is provided | ||
if [ "$#" -ne 2 ]; then | ||
echo "Usage: $0 <folder_path> <text>" | ||
exit 1 | ||
fi | ||
|
||
FOLDER_PATH=$1 | ||
TEXT=$2 | ||
|
||
# Check if the folder exists | ||
if [ ! -d "$FOLDER_PATH" ]; then | ||
echo "Folder $FOLDER_PATH does not exist." | ||
exit 1 | ||
fi | ||
|
||
# Create a temporary text image | ||
TEXT_IMAGE="text_image.png" | ||
convert -background none -fill white -pointsize 24 -gravity SouthEast label:"$TEXT" "$TEXT_IMAGE" | ||
|
||
# Loop through each image in the folder | ||
for IMAGE in "$FOLDER_PATH"/*; do | ||
if [ -f "$IMAGE" ]; then | ||
# Add text to the lower right part of the image | ||
composite -gravity SouthEast "$TEXT_IMAGE" "$IMAGE" "$IMAGE" | ||
echo "Processed $IMAGE" | ||
fi | ||
done | ||
|
||
# Remove the temporary text image | ||
rm "$TEXT_IMAGE" | ||
|
||
echo "All images processed." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,274 @@ | ||
//go:build e2e | ||
|
||
package tests | ||
|
||
import ( | ||
"context" | ||
"reflect" | ||
"testing" | ||
|
||
"github.com/simulot/immich-go/app/cmd" | ||
"github.com/simulot/immich-go/internal/e2eTests/e2e" | ||
"github.com/simulot/immich-go/internal/fileevent" | ||
) | ||
|
||
func TestBurstsFolders(t *testing.T) { | ||
t.Run("camera burst raw+jpg, Stack", func(t *testing.T) { | ||
const source = "DATA/bursts/jpg" | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
// client, err := e2e.GetImmichClient() | ||
// if err != nil { | ||
// t.Fatal(err) | ||
// return | ||
// } | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=Stack", | ||
source, | ||
}) | ||
err := c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 11, | ||
fileevent.Stacked: 7, | ||
}, false, a.Jnl()) | ||
|
||
// sourceDir := e2e.ScanDirectory(t, source) | ||
// serverAssets := e2e.ImmichScan(t, client) | ||
// upFiles := e2e.ExtensionFilter(sourceDir, []string{".cr3"}) | ||
// if !reflect.DeepEqual(serverAssets, upFiles) { | ||
// t.Error("Unexpected assets on server", serverAssets, "expected", upFiles) | ||
// } | ||
}) | ||
t.Run("camera burst raw+jpg Stack", func(t *testing.T) { | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=Stack", | ||
"DATA/bursts/raw-jpg", | ||
}) | ||
err := c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 8, | ||
fileevent.Stacked: 8, | ||
}, false, a.Jnl()) | ||
}) | ||
t.Run("camera burst raw+jpg, stack StackKeepRaw", func(t *testing.T) { | ||
const source = "DATA/bursts/raw-jpg" | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
client, err := e2e.GetImmichClient() | ||
if err != nil { | ||
t.Fatal(err) | ||
return | ||
} | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=StackKeepRaw", | ||
source, | ||
}) | ||
err = c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 4, | ||
fileevent.Stacked: 4, | ||
fileevent.DiscoveredDiscarded: 4, | ||
}, false, a.Jnl()) | ||
|
||
sourceDir := e2e.ScanDirectory(t, source) | ||
serverAssets := e2e.ImmichScan(t, client) | ||
upFiles := e2e.ExtensionFilter(sourceDir, []string{".cr3"}) | ||
if !reflect.DeepEqual(serverAssets, upFiles) { | ||
t.Error("Unexpected assets on server", serverAssets, "expected", upFiles) | ||
} | ||
}) | ||
|
||
t.Run("camera burst raw+jpg, stack StackKeepJPEG", func(t *testing.T) { | ||
const source = "DATA/bursts/raw-jpg" | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
client, err := e2e.GetImmichClient() | ||
if err != nil { | ||
t.Fatal(err) | ||
return | ||
} | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=StackKeepJPEG", | ||
source, | ||
}) | ||
err = c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 4, | ||
fileevent.Stacked: 4, | ||
fileevent.DiscoveredDiscarded: 4, | ||
}, false, a.Jnl()) | ||
|
||
sourceDir := e2e.ScanDirectory(t, source) | ||
serverAssets := e2e.ImmichScan(t, client) | ||
upFiles := e2e.ExtensionFilter(sourceDir, []string{".jpg"}) | ||
if !reflect.DeepEqual(serverAssets, upFiles) { | ||
t.Error("Unexpected assets on server", serverAssets, "expected", upFiles) | ||
} | ||
}) | ||
|
||
t.Run("phone burst", func(t *testing.T) { | ||
const source = "DATA/bursts/phone" | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
client, err := e2e.GetImmichClient() | ||
if err != nil { | ||
t.Fatal(err) | ||
return | ||
} | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=Stack", | ||
source, | ||
}) | ||
err = c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 7, | ||
fileevent.Stacked: 7, | ||
fileevent.DiscoveredDiscarded: 0, | ||
}, false, a.Jnl()) | ||
|
||
sourceDir := e2e.ScanDirectory(t, source) | ||
serverAssets := e2e.ImmichScan(t, client) | ||
upFiles := e2e.ExtensionFilter(sourceDir, []string{".jpg"}) | ||
if !reflect.DeepEqual(serverAssets, upFiles) { | ||
t.Error("Unexpected assets on server", serverAssets, "expected", upFiles) | ||
} | ||
}) | ||
|
||
t.Run("phone jpg burst but keepRaw ", func(t *testing.T) { | ||
const source = "DATA/bursts/phone" | ||
e2e.InitMyEnv() | ||
e2e.ResetImmich(t) | ||
client, err := e2e.GetImmichClient() | ||
if err != nil { | ||
t.Fatal(err) | ||
return | ||
} | ||
|
||
ctx := context.Background() | ||
c, a := cmd.RootImmichGoCommand(ctx) | ||
c.SetArgs([]string{ | ||
"upload", "from-folder", | ||
"--server=" + e2e.MyEnv("IMMICHGO_SERVER"), | ||
"--api-key=" + e2e.MyEnv("IMMICHGO_APIKEY"), | ||
"--no-ui", | ||
"--api-trace", | ||
"--log-level=debug", | ||
"--manage-burst=StackKeepRaw", | ||
source, | ||
}) | ||
err = c.ExecuteContext(ctx) | ||
if err != nil && a.Log().GetSLog() != nil { | ||
a.Log().Error(err.Error()) | ||
} | ||
|
||
if err != nil { | ||
t.Error("Unexpected error", err) | ||
return | ||
} | ||
|
||
e2e.CheckResults(t, map[fileevent.Code]int64{ | ||
fileevent.Uploaded: 7, | ||
fileevent.Stacked: 7, | ||
fileevent.DiscoveredDiscarded: 0, | ||
}, false, a.Jnl()) | ||
|
||
sourceDir := e2e.ScanDirectory(t, source) | ||
serverAssets := e2e.ImmichScan(t, client) | ||
upFiles := e2e.ExtensionFilter(sourceDir, []string{".jpg"}) | ||
if !reflect.DeepEqual(serverAssets, upFiles) { | ||
t.Error("Unexpected assets on server", serverAssets, "expected", upFiles) | ||
} | ||
}) | ||
} |
Oops, something went wrong.