Skip to content

Commit

Permalink
fix: correções teste funcional postgresql
Browse files Browse the repository at this point in the history
  • Loading branch information
Mauro Costa committed Sep 4, 2024
1 parent 9176ba3 commit 3c7dfe1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 10 deletions.
17 changes: 9 additions & 8 deletions src/scripts/sei_atualizar_versao_modulo_pen.php
Original file line number Diff line number Diff line change
Expand Up @@ -2874,14 +2874,15 @@ protected function instalarV3070()
$blocosTramite = $objInfraBanco->consultarSql($sql);

// Alterar colunas em md_pen_expedir_lote
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_repositorio_destino', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'str_repositorio_destino', $objMetaBD->tipoTextoVariavel(250), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_repositorio_origem', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade_origem', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade_destino', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'str_unidade_destino', $objMetaBD->tipoTextoVariavel(250), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_usuario', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade', $objMetaBD->tipoNumero(), PenMetaBD::SNULLO);
$SNULLO = BancoSEI::getInstance() instanceof InfraPostgreSql ? 'null' : PenMetaBD::SNULLO;
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_repositorio_destino', $objMetaBD->tipoNumero(), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'str_repositorio_destino', $objMetaBD->tipoTextoVariavel(250), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_repositorio_origem', $objMetaBD->tipoNumero(), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade_origem', $objMetaBD->tipoNumero(), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade_destino', $objMetaBD->tipoNumero(), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'str_unidade_destino', $objMetaBD->tipoTextoVariavel(250), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_usuario', $objMetaBD->tipoNumero(), $SNULLO);
$objMetaBD->alterarColuna('md_pen_expedir_lote', 'id_unidade', $objMetaBD->tipoNumero(), $SNULLO);

// Alterar id da tabela
$this->excluirChaveEstrangeira("md_pen_rel_expedir_lote", "fk_md_pen_rel_expedir_lote", true);
Expand Down
11 changes: 9 additions & 2 deletions tests_super/funcional/src/paginas/PaginaLogin.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

use PHPUnit\Extensions\Selenium2TestCase\WebDriverException;

class PaginaLogin extends PaginaTeste
{
public function __construct($test)
Expand All @@ -8,8 +10,13 @@ public function __construct($test)
parent::__construct($test);
$this->usuarioInput = $test->byId('txtUsuario');
$this->passwordInput = $test->byId('pwdSenha');
$this->loginButton = $test->byId('Acessar');

try{
$this->loginButton = $test->byId('Acessar');
}
//SEI 4.0.12 alterou para sbmAcessar
catch (WebDriverException $wde){
$this->loginButton = $test->byId('sbmAcessar');
}
}

public function usuario($value)
Expand Down

0 comments on commit 3c7dfe1

Please sign in to comment.