예제 #1
0
        public async Task Check()
        {
            await Task.CompletedTask;

            //cmdDocker.ImageExists(name,tag)
            StepAssert.IsTrue(false);
        }
예제 #2
0
        public async Task Check()
        {
            IAuthenticationInfo auth = new UserPasswordAuthenticationInfo(
                await listAsk.LocalVaultDevopUser.Ask(),
                await listAsk.LocalVaultDevopPassword.Ask());

            StepAssert.IsTrue(null != await listResources.CAKey.Read(auth));
            StepAssert.IsTrue(null != await listResources.CAPem.Read(auth));
        }
예제 #3
0
        public void Check(ICommandExecute execute)
        {
            StepAssert.Contains("\"initialized\":true,\"sealed\":false", execute.Command("curl http://localhost:8200/v1/sys/health"));

            // login for test user
            var data     = " --data '{\"password\": \"test\"}' ";
            var loginCmd = "curl --request POST " + data + " http://127.0.0.1:8200/v1/auth/userpass/login/test ";

            dynamic loginResponse = JObject.Parse(execute.Command(loginCmd));
            var     token         = (string)loginResponse.auth.client_token;

            StepAssert.IsTrue(!string.IsNullOrWhiteSpace(token));

            /*
             * // Try to read the test value with the test user/password
             * var header = " --header \"X-Vault-Token: " + token + "\" ";
             * var readCmd = "curl " + token + " http://127.0.0.1:8200/v1/secret/test";
             * var readCmdResponse = execute.Command(readCmd);
             * StepAssert.AreEqual("testValue", readCmdResponse);
             */
        }