test(authz-jwt): fix flaky test t_check_expire
This commit is contained in:
parent
1597ea50c1
commit
4989ce7a0d
|
@ -245,7 +245,7 @@ t_check_expire(_Config) ->
|
|||
Payload = #{
|
||||
<<"username">> => <<"username">>,
|
||||
<<"acl">> => #{<<"sub">> => [<<"a/b">>]},
|
||||
<<"exp">> => erlang:system_time(second) + 1
|
||||
<<"exp">> => erlang:system_time(second) + 5
|
||||
},
|
||||
|
||||
JWT = generate_jws(Payload),
|
||||
|
@ -270,7 +270,7 @@ t_check_expire(_Config) ->
|
|||
emqtt:unsubscribe(C, <<"a/b">>)
|
||||
),
|
||||
|
||||
timer:sleep(2000),
|
||||
timer:sleep(6000),
|
||||
|
||||
?assertMatch(
|
||||
{ok, #{}, [?RC_NOT_AUTHORIZED]},
|
||||
|
|
Loading…
Reference in New Issue