Update on Overleaf.

This commit is contained in:
nb72soza Bittner
2025-06-28 18:43:56 +00:00
committed by node
parent 5483c20352
commit eb62ed381e
3 changed files with 101 additions and 29 deletions

View File

@@ -509,7 +509,7 @@ Hypothesis is a property-based testing framework, which allows developers to def
Hypothesis integrates seamlessly with \texttt{pytest} and uses the \texttt{@given} decorator to specify input generation strategies. For example, given the \gls{asn1} structure defined in the \gls{sgp22} specification for the \texttt{GetProfileInfo} function:
\begin{verbatim}
\begin{lstlisting}[caption={ASN.1 definition of the ProfileInfoListRequest}]
ProfileInfoListRequest ::= [45] SEQUENCE {
searchCriteria [0] CHOICE {
isdpAid [APPLICATION 15] OctetTo16,
@@ -518,11 +518,11 @@ ProfileInfoListRequest ::= [45] SEQUENCE {
} OPTIONAL,
tagList [APPLICATION 28] OCTET STRING OPTIONAL
}
\end{verbatim}
\end{lstlisting}
We define the following Hypothesis test for the Python implementation of \texttt{GetProfileInfo}:
\begin{lstlisting}[language=Python, caption={Hypothesis-based fuzzing of \texttt{GetProfileInfo}}]
\begin{lstlisting}[language=Python, caption={Hypothesis-based fuzzing of \texttt{GetProfileInfo} function which sends a \texttt{ProfileInfoListRequest}.}]
@given(
use_iccid=st.booleans(),
profile_class=st.one_of(st.integers(min_value=-20, max_value=20), st.none()),