keycloak-scim/testsuite/integration-arquillian/tests/other/adapters/wls/wls12
2018-12-04 13:54:25 +01:00
..
src/test/java/org/keycloak/testsuite/adapter KEYCLOAK-6745 Adapter tests - remove abstract adapter test classes 2018-06-11 13:46:59 +02:00
pom.xml Prepare for 4.8.0.Final 2018-12-04 13:54:25 +01:00
README.md KEYCLOAK-6546 Run filter test on WebLogic and WebSphere 2018-02-26 15:47:13 +01:00

For running WebLogic tests you need to have WLS running on port 8280 on your local machine.

Running WLS server

Run WebLogic server on port 8280

For example for docker image it is necessary to run it with these arguments

docker run -d \
--name="wls-server" \
--net="host" \
-v /tmp:/tmp \
your_docker_image
  • We need to use --net="host" so that weblogic can access Keycloak server
  • Also we need to map /tmp directory to /tmp directory in docker. This way arquillian will move archives used in testsuite to docker filesystem so that they are deployed to WLS
- And also our image always create new admin password when starting weblogic so you need to find out what password it generated
```bash
docker logs wls-server | grep password

Running tests

  1. At first we need to add our custom arquillian remote adapter to local repository. Only custom change is to always store tmp files in /tmp
git clone https://github.com/mhajas/arquillian-container-wls.git
cd arquillian-container-wls/wls-common
mvn clean install -DskipTests [-Dmaven.repo.local=/custom/repo/path]
cd ../wls-remote-12.1.x
mvn clean install -DskipTests [-Dmaven.repo.local=/custom/repo/path]
  1. Build testsuite-arquillian
mvn clean install -f testsuite/integration-arquillian/pom.xml -DskipTests=true
  1. Run tests
mvn clean install -f testsuite/integration-arquillian/tests/other/pom.xml -Papp-server-wls -Dwl.username=${admin-username} -Dwl.password=${admin-password} -Dwl.home=${wl-home-path}

In case of docker image one can replace wl-home-path with some preprepared directory which contains these files (example of downloading files):

docker cp wls-server:/u01/oracle/wlserver/server/lib/weblogic.jar ${wl-home-path}/server/lib/
docker cp wls-server:/u01/oracle/wlserver/server/lib/wlclient.jar ${wl-home-path}/server/lib/
docker cp wls-server:/u01/oracle/wlserver/server/lib/wljmxclient.jar ${wl-home-path}/server/lib/