File tree Expand file tree Collapse file tree
examples/security/jwt/verification
src/test/java/com/predic8/membrane/examples/withoutinternet Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ @ echo off
2+ setlocal EnableExtensions
3+
4+ set " SCRIPT_DIR = %~dp0 "
5+ if " %SCRIPT_DIR:~-1 % " == " \" set " SCRIPT_DIR = %SCRIPT_DIR:~0 ,-1 % "
6+
7+ set " dir = %SCRIPT_DIR% "
8+
9+ :search_up
10+ if exist " %dir% \LICENSE.txt" if exist " %dir% \scripts\run-membrane.cmd" goto found
11+ for %%A in (" %dir% \.." ) do set " next = %%~fA "
12+ if /I " %next% " == " %dir% " goto notfound
13+ set " dir = %next% "
14+ goto search_up
15+
16+ :found
17+ set " MEMBRANE_HOME = %dir% "
18+ set " MEMBRANE_CALLER_DIR = %SCRIPT_DIR% "
19+ call " %MEMBRANE_HOME% \scripts\run-membrane.cmd" %*
20+ exit /b %ERRORLEVEL%
21+
22+ :notfound
23+ >& 2 echo Could not locate Membrane root. Ensure directory structure is correct.
24+ exit /b 1
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+ # Default: ./proxies.xml (next to this script); fallback -> $MEMBRANE_HOME/conf/proxies.xml
3+ # JAVA_OPTS: relative -D paths are auto-resolved against $MEMBRANE_HOME (absolute/URI unchanged).
4+ # Examples:
5+ # export JAVA_OPTS='-Dlog4j.configurationFile=examples/logging/access/log4j2_access.xml'
6+ # export JAVA_OPTS='-Dlog4j.configurationFile=/abs/path/log4j2.xml'
7+
8+ SCRIPT_DIR=$( CDPATH= cd -- " $( dirname -- " $0 " ) " && pwd -P)
9+
10+ dir=" $SCRIPT_DIR "
11+ while [ " $dir " != " /" ]; do
12+ if [ -f " $dir /LICENSE.txt" ] && [ -f " $dir /scripts/run-membrane.sh" ]; then
13+ export MEMBRANE_HOME=" $dir "
14+ export MEMBRANE_CALLER_DIR=" $SCRIPT_DIR "
15+ exec sh " $dir /scripts/run-membrane.sh" " $@ "
16+ fi
17+ dir=$( dirname " $dir " )
18+ done
19+
20+ echo " Could not locate Membrane root. Ensure directory structure is correct." >&2
21+ exit 1
Original file line number Diff line number Diff line change 1414
1515package com .predic8 .membrane .examples .withoutinternet ;
1616
17- import com .predic8 .membrane .core .http .Header ;
1817import com .predic8 .membrane .examples .util .AbstractSampleMembraneStartStopTestcase ;
19- import org .jetbrains .annotations .NotNull ;
2018import org .junit .jupiter .api .Test ;
2119
22- import java .util .concurrent .atomic .AtomicBoolean ;
23-
2420import static io .restassured .RestAssured .given ;
25- import static org .junit .jupiter .api .Assertions .assertTrue ;
2621
2722public class JwtVerificationExampleTest extends AbstractSampleMembraneStartStopTestcase {
2823
You can’t perform that action at this time.
0 commit comments