[almighty] Starting a thread - how to best simulate a user login in ALMighty UI for test purposes?

Aslak Knutsen aslak at redhat.com
Fri Nov 4 19:04:09 UTC 2016


Agree, we need both. Just at different stages of testing.

-aslak-

On Fri, Nov 4, 2016 at 3:39 PM, Todd Mancini <tmancini at redhat.com> wrote:

> Why not both?
>
> GitHub was victim of the Dyn attack a couple of weeks ago, so a test
> directly against GitHub likely would have failed at that point --
>  therefore also having a simulated login test that passed would have helped
> to identify that the problem was 'elsewhere'.
>
> On Fri, Nov 4, 2016 at 8:52 AM, Leonard Dimaggio <ldimaggi at redhat.com>
> wrote:
>
>> P.S. For End-to-end tests, I am still leaning toward creating a test
>> account at github as opposed to simulating login - 'opinions anyone?
>>
>> -- Len
>>
>> On Fri, Nov 4, 2016 at 8:28 AM, Leonard Dimaggio <ldimaggi at redhat.com>
>> wrote:
>>
>>> Aslak,
>>>
>>> Can we rely on this endpoint always being supported - provided that a
>>> server is run in dev mode?
>>>     http://localhost:8080/api/login/generate
>>>
>>>
>>> Thanks!,
>>> Len
>>>
>>>
>>> On Fri, Oct 28, 2016 at 5:44 AM, Aslak Knutsen <aslak at redhat.com> wrote:
>>>
>>>> In "Continuous Enterprise Development in Java" we didn't fake it, we
>>>> actually did a full-scale login. We did it in the background as an
>>>> Arquillian extension to avoid the TestCase having to care about it. The
>>>> test case was written without security in mind, but security was enabled in
>>>> the background if setup required it. (e.g. same test case could be used as
>>>> an integration and full functional test)
>>>>
>>>> Example using htmlunit to do a login cycle to get a session/token using
>>>> Twitter as provider:
>>>> https://github.com/arquillian/continuous-enterprise-developm
>>>> ent/blob/master/code/application/service/security/src/test/j
>>>> ava/org/cedj/geekseek/service/security/test/arquillian/Twitt
>>>> erLogin.java
>>>>
>>>> It requires the username/password secrets to run, but that's the only
>>>> way as far as I know to do a full test.
>>>>
>>>> Depending on the level of testing you're asking for, there is a REST
>>>> API to call to get valid tokens that are open if you run the server in dev
>>>> mode:
>>>>
>>>>     ALMIGHTY_DEVELOPER_MODE_ENABLED=1 ./bin/alm
>>>>
>>>>     http://localhost:8080/api/login/generate
>>>>
>>>>
>>>> -aslak-
>>>>
>>>>
>>>> On Thu, Oct 27, 2016 at 3:50 PM, Konrad Kleine <kkleine at redhat.com>
>>>> wrote:
>>>>
>>>>> Hi Len,
>>>>>
>>>>> a quick search for OAuth Test revealed a site that seems to provide a
>>>>> test server: http://term.ie/oauth/example/ and a test client:
>>>>> http://term.ie/oauth/example/client.php
>>>>>
>>>>> Maybe this is worth looking into.
>>>>>
>>>>> Regards,
>>>>> Konrad
>>>>>
>>>>>
>>>>>
>>>>> On Thu, Oct 27, 2016 at 3:28 PM, Michael Kleinhenz <
>>>>> kleinhenz at redhat.com> wrote:
>>>>>
>>>>>>
>>>>>> Can we mock the GitHub AuthN? It's just oAuth, right?
>>>>>>
>>>>>>
>>>>>> On Thu, Oct 27, 2016 at 3:08 PM, Leonard Dimaggio <
>>>>>> ldimaggi at redhat.com> wrote:
>>>>>>
>>>>>>> Hey everyone,
>>>>>>>
>>>>>>> I wanted to get input from people on the best way to mock/simulate a
>>>>>>> login to ALMighty for testing. We currently use a fake login for these
>>>>>>> tests (https://github.com/almighty/almighty-ui/tree/master/src/tes
>>>>>>> ts/work-item/work-item-list) - but we also want to be able to
>>>>>>> automate the testing of actual logins.
>>>>>>>
>>>>>>> Please reply all with ideas - suggestions, etc.
>>>>>>>
>>>>>>> Thanks!,
>>>>>>> Len D.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Len DiMaggio (ldimaggi at redhat.com)
>>>>>>> JBoss by Red Hat
>>>>>>> 314 Littleton Road
>>>>>>> Westford, MA 01886  USA
>>>>>>> tel:  978.392.3179
>>>>>>> cell: 781.472.9912
>>>>>>> http://www.redhat.com
>>>>>>> http://community.jboss.org/people/ldimaggio
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> almighty-public mailing list
>>>>>>> almighty-public at redhat.com
>>>>>>> https://www.redhat.com/mailman/listinfo/almighty-public
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Michael Kleinhenz
>>>>>> Principal Software Engineer
>>>>>>
>>>>>> Red Hat Deutschland GmbH
>>>>>> Werner-von-Siemens-Ring 14
>>>>>> 85630 Grasbrunn
>>>>>> Germany
>>>>>>
>>>>>> RED HAT | TRIED. TESTED. TRUSTED.
>>>>>> Red Hat GmbH, www.de.redhat.com,
>>>>>> Registered seat: Grasbrunn, Commercial register: Amtsgericht München,
>>>>>> HRB 153243,
>>>>>> Managing Directors: Paul Argiry, Charles Cachera, Michael Cunningham,
>>>>>> Michael O'Neill
>>>>>>
>>>>>> _______________________________________________
>>>>>> almighty-public mailing list
>>>>>> almighty-public at redhat.com
>>>>>> https://www.redhat.com/mailman/listinfo/almighty-public
>>>>>>
>>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> almighty-public mailing list
>>>>> almighty-public at redhat.com
>>>>> https://www.redhat.com/mailman/listinfo/almighty-public
>>>>>
>>>>>
>>>>
>>>> _______________________________________________
>>>> almighty-public mailing list
>>>> almighty-public at redhat.com
>>>> https://www.redhat.com/mailman/listinfo/almighty-public
>>>>
>>>>
>>>
>>>
>>> --
>>> Len DiMaggio (ldimaggi at redhat.com)
>>> JBoss by Red Hat
>>> 314 Littleton Road
>>> Westford, MA 01886  USA
>>> tel:  978.392.3179
>>> cell: 781.472.9912
>>> http://www.redhat.com
>>> http://community.jboss.org/people/ldimaggio
>>>
>>>
>>>
>>
>>
>> --
>> Len DiMaggio (ldimaggi at redhat.com)
>> JBoss by Red Hat
>> 314 Littleton Road
>> Westford, MA 01886  USA
>> tel:  978.392.3179
>> cell: 781.472.9912
>> http://www.redhat.com
>> http://community.jboss.org/people/ldimaggio
>>
>>
>>
>> _______________________________________________
>> almighty-public mailing list
>> almighty-public at redhat.com
>> https://www.redhat.com/mailman/listinfo/almighty-public
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/almighty-public/attachments/20161104/3c537ae7/attachment.htm>


More information about the almighty-public mailing list