ai cooking
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

be more precise with whats saved/deismissed

+17 -3
.beads/issues.jsonl

This is a binary file and will not be displayed.

+17 -3
cmd/careme/web_e2e_test.go
··· 60 60 savedHash := recipeHashes[0] 61 61 dismissedHashes := recipeHashes[1:3] 62 62 63 - // Step 4: finalize with the saved/dismissed selections. 63 + //step 4 todo regenrate again with commentary then save two more 64 + 65 + // Step 5: finalize with the saved/dismissed selections. 64 66 finalizeURL := buildRecipesURL(srv.URL, location, date, conversationID, savedHash, dismissedHashes, true) 65 67 _, finalizedBody := followUntilRecipes(t, client, finalizeURL) 66 - if countArticles(finalizedBody) != 1 { 67 - t.Fatalf("expected finalized page to show 1 recipe, got %d", countArticles(finalizedBody)) 68 + recipeHashes = extractRecipeHashes(t, finalizedBody) 69 + if len(recipeHashes) != 1 { 70 + t.Fatalf("expected finalized page to show 1 recipe, got %d", len(recipeHashes)) 68 71 } 72 + if recipeHashes[0] != savedHash { 73 + t.Fatalf("expected finalized recipe to be %s, got %s", savedHash, recipeHashes[0]) 74 + } 75 + for _, dismissed := range dismissedHashes { 76 + if recipeHashes[0] == dismissed { 77 + t.Fatalf("finalized recipe %s was in dismissed list", dismissed) 78 + } 79 + } 80 + 69 81 } 70 82 71 83 func newTestServer(t *testing.T) *httptest.Server { ··· 210 222 return strings.Contains(body, "<title>Generating") || strings.Contains(body, "Please wait") 211 223 } 212 224 225 + //basically makes relative ref full based on host from base 226 + // just hard code a host somewhere in the test instead? 213 227 func resolveURL(t *testing.T, base, ref string) string { 214 228 t.Helper() 215 229 baseURL, err := url.Parse(base)