Skip to content

Commit

Permalink
bump yume to 0.1.6 to parse formdata large image
Browse files Browse the repository at this point in the history
  • Loading branch information
ushitora-anqou committed Jun 2, 2024
1 parent 77ba567 commit 780d3e4
Show file tree
Hide file tree
Showing 3 changed files with 84 additions and 3 deletions.
81 changes: 81 additions & 0 deletions e2e/src/common.ml
Original file line number Diff line number Diff line change
Expand Up @@ -832,3 +832,84 @@ ADIwMjMtMDMtMjJUMDI6Mzc6NTgrMDA6MDClQ3CPAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIzLTAz
LTIyVDAyOjM3OjU4KzAwOjAw1B7IMwAAAABJRU5ErkJggg==|}
|> String.trim |> String.split_on_char '\n' |> String.concat ""
|> Base64.decode_exn

let test_image_large =
{|
iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAIAAABuP+aXAAABfGlDQ1BpY2MAACiRfZE9SMNAHMVf
U2tVKh3sIOKQoTrZRUUcaxWKUKHUCq06mFz6BU0akhQXR8G14ODHYtXBxVlXB1dBEPwAcXVxUnSR
Ev+XFFrEeHDcj3f3HnfvAKFZZarZEwdUzTIyyYSYy6+KwVcEEEY/guiVmKnPpdMpeI6ve/j4ehfj
Wd7n/hyDSsFkgE8kjjPdsIg3iGc2LZ3zPnGElSWF+Jx4wqALEj9yXXb5jXPJYYFnRoxsZp44QiyW
uljuYlY2VOJp4qiiapQv5FxWOG9xVqt11r4nf2GooK0sc53mKJJYxBLSECGjjgqqsBCjVSPFRIb2
Ex7+EcefJpdMrgoYORZQgwrJ8YP/we9uzeLUpJsUSgCBF9v+GAOCu0CrYdvfx7bdOgH8z8CV1vHX
msDsJ+mNjhY9AsLbwMV1R5P3gMsdYPhJlwzJkfw0hWIReD+jb8oDQ7fAwJrbW3sfpw9AlrpK3QAH
h8B4ibLXPd7d193bv2fa/f0ABFpyenpicbcAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADq
YAAAOpgAABdwnLpRPAAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlz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gANAAAAnAAAADIBAgAUAAAAqgAAAGmHBAABAAAAvgAAAAAAAAAIAAgACABIAAAAAQAA
AEgAAAABAAAAR0lNUCAyLjEwLjM0AAAyMDIzOjA1OjE1IDE4OjA5OjE0AAEAAaADAAEAAAABAAAA
AAAAAEf4jE8AAAAldEVYdGRhdGU6Y3JlYXRlADIwMjQtMDYtMDJUMDk6MTM6MzArMDA6MDBp4rJK
AAAAJXRFWHRkYXRlOm1vZGlmeQAyMDI0LTA2LTAyVDA5OjEzOjMwKzAwOjAwGL8K9gAAABp0RVh0
ZXhpZjpCaXRzUGVyU2FtcGxlADgsIDgsIDgS7T4nAAAAEXRFWHRleGlmOkNvbG9yU3BhY2UAMQ+b
AkkAAAAhdEVYdGV4aWY6RGF0ZVRpbWUAMjAyMzowNToxNSAxODowOToxNBJwRVYAAAATdEVYdGV4
aWY6RXhpZk9mZnNldAAxOTBMjvPCAAAAFHRFWHRleGlmOkltYWdlTGVuZ3RoADI0MvW9M3QAAAAT
dEVYdGV4aWY6SW1hZ2VXaWR0aAAyNDImwSP5AAAAGnRFWHRleGlmOlNvZnR3YXJlAEdJTVAgMi4x
MC4zNBhmc5oAAAAbdEVYdGljYzpjb3B5cmlnaHQAUHVibGljIERvbWFpbraRMVsAAAAidEVYdGlj
YzpkZXNjcmlwdGlvbgBHSU1QIGJ1aWx0LWluIHNSR0JMZ0ETAAAAFXRFWHRpY2M6bWFudWZhY3R1
cmVyAEdJTVBMnpDKAAAADnRFWHRpY2M6bW9kZWwAc1JHQltgSUMAAAAASUVORK5CYII=|}
|> String.trim |> String.split_on_char '\n' |> String.concat ""
|> Base64.decode_exn
4 changes: 2 additions & 2 deletions e2e/src/waq_mstdn_10_attachment.ml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ let f env (a0 : agent) (a1 : agent) =

(* a1: Post with attachments *)
let ({ id = media_id; _ } : media_attachment) =
upload_media env a1 ~filename:"test0.png" ~data:test_image
upload_media env a1 ~filename:"test0.png" ~data:test_image_large
~content_type:"image/png"
in
let ({ id = media_id2; _ } : media_attachment) =
upload_media env a1 ~filename:"test1.png" ~data:test_image
upload_media env a1 ~filename:"test1.png" ~data:test_image_large
~content_type:"image/png"
in
let { uri; media_attachments; _ } =
Expand Down
2 changes: 1 addition & 1 deletion waq.opam
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,5 @@ pin-depends:[
[ "websocket.2.16" "git+https://github.com/ushitora-anqou/ocaml-websocket#74988ec5ec7d7c620e7d58c5509acd003107c513" ]
[ "multipart_form.0.5.0" "git+https://github.com/dinosaure/multipart_form#a794239b8fc9601540ffea489b2c470227216c5e" ]
[ "multipart_form-eio.0.5.0" "git+https://github.com/dinosaure/multipart_form#a794239b8fc9601540ffea489b2c470227216c5e" ]
[ "yume.0.1.5" "git+https://github.com/ushitora-anqou/yume.git#0.1.5" ]
[ "yume.0.1.6" "git+https://github.com/ushitora-anqou/yume.git#0.1.6" ]
]

0 comments on commit 780d3e4

Please sign in to comment.