aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/synth/case02/tb_case01.vhdl
blob: 95b8561d8a8db83db030f8d05a2088f87154f4e6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
entity tb_case01 is
end tb_case01;

library ieee;
use ieee.std_logic_1164.all;

architecture behav of tb_case01 is
  signal a : std_logic_vector (1 downto 0);
  signal o : std_logic_vector (1 downto 0);
  signal clk : std_logic;
begin
  dut: entity work.case01
    port map (a, clk, o);

  process
    procedure pulse is
    begin
      clk <= '0';
      wait for 1 ns;
      clk <= '1';
      wait for 1 ns;
    end pulse;
  begin
    a <= "00";
    pulse;
    a <= "10";
    pulse;
    assert o = "00" severity failure;

    wait;
  end process;
end behav;