'http_get' is one of the few samples that just require connection to internet (google.com over HTTP or HTTPS) and check if HTTP GET was successful. Use it for minimal coverage of Native Simulator offloaded sockets: * DNS resolving * basic TCP transfer * compatibility with Zephyr TLS subsystem (which required some fcntl() operations) Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
61 lines
1.5 KiB
YAML
61 lines
1.5 KiB
YAML
sample:
|
|
description: BSD Sockets API HTTP GET example
|
|
name: socket_http_get
|
|
common:
|
|
filter: CONFIG_FULL_LIBC_SUPPORTED
|
|
min_ram: 32
|
|
min_flash: 80
|
|
tags:
|
|
- net
|
|
- socket
|
|
tests:
|
|
sample.net.sockets.http_get:
|
|
harness: net
|
|
extra_configs:
|
|
- CONFIG_NET_SOCKETS_POSIX_NAMES=y
|
|
# Forcibly defines CONFIG_POSIX_API, which is incompatible with
|
|
# CONFIG_NET_SOCKETS_POSIX_NAMES.
|
|
sample.net.sockets.http_get.posix:
|
|
filter: not CONFIG_NET_SOCKETS_OFFLOAD and not CONFIG_NATIVE_LIBC
|
|
harness: net
|
|
platform_exclude:
|
|
- cc3220sf_launchxl
|
|
- cc3235sf_launchxl
|
|
extra_configs:
|
|
- CONFIG_NET_SOCKETS_POSIX_NAMES=n
|
|
- CONFIG_POSIX_API=y
|
|
sample.net.sockets.http_get.offload.simplelink:
|
|
platform_allow: cc3220sf_launchxl
|
|
harness: net
|
|
tags:
|
|
- net
|
|
- socket
|
|
- offload
|
|
- simplelink
|
|
sample.get.sockets.http_get.nsos.http:
|
|
harness: console
|
|
harness_config:
|
|
type: multi_line
|
|
ordered: true
|
|
regex:
|
|
- "(.*)<BODY>(.*)"
|
|
- "The document has moved"
|
|
- "(.*)</BODY>(.*)"
|
|
platform_allow:
|
|
- native_sim
|
|
- native_sim/native/64
|
|
extra_args: OVERLAY_CONFIG="overlay-nsos.conf"
|
|
sample.get.sockets.http_get.nsos.https:
|
|
harness: console
|
|
harness_config:
|
|
type: multi_line
|
|
ordered: true
|
|
regex:
|
|
- "(.*)<BODY>(.*)"
|
|
- "The document has moved"
|
|
- "(.*)</BODY>(.*)"
|
|
platform_allow:
|
|
- native_sim
|
|
- native_sim/native/64
|
|
extra_args: OVERLAY_CONFIG="overlay-nsos.conf;overlay-tls.conf"
|