Fakultas Ilmu Komputer UI

Commit 89758d6f authored by Yaumi's avatar Yaumi
Browse files

[REFACTOR] refactor test

parents c8ee9b33 f7c75835
Pipeline #58174 failed with stages
in 13 minutes and 6 seconds
......@@ -15,6 +15,7 @@ media
/static/
media/
.coverage
virtualenv
# If your build process includes running collectstatic, then you probably don't need or want to include staticfiles/
# in your Git repository. Update and uncomment the following line accordingly.
......
......@@ -68,7 +68,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
......
......@@ -4,6 +4,7 @@
<html lang="en">
<!-- Static assets -->
<head>
<title>Digipus</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
......@@ -67,7 +68,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
......
......@@ -28,7 +28,7 @@
<div class="h5 mb-0 font-weight-bold text-gray-800">{{chart_data.total.0}}</div>
</div>
<div class="col-auto">
<i class="fas fa-eye" aria-hidden="true"></i>
<em class="fas fa-eye" aria-hidden="true"></em>
</div>
</div>
</div>
......@@ -45,7 +45,7 @@
<div class="h5 mb-0 font-weight-bold text-gray-800">{{chart_data.total.1}}</div>
</div>
<div class="col-auto">
<i class="fas fa-download" aria-hidden="true"></i>
<em class="fas fa-download" aria-hidden="true"></em>
</div>
</div>
</div>
......@@ -62,7 +62,7 @@
<div class="h5 mb-0 font-weight-bold text-gray-800">{{chart_data.total.2}}</div>
</div>
<div class="col-auto">
<i class="fas fa-thumbs-up" aria-hidden="true"></i>
<em class="fas fa-thumbs-up" aria-hidden="true"></em>
</div>
</div>
</div>
......@@ -79,7 +79,7 @@
<div class="h5 mb-0 font-weight-bold text-gray-800">{{chart_data.total.3}}</div>
</div>
<div class="col-auto">
<i class="fas fa-comments fa-2x text-gray-300"></i>
<em class="fas fa-comments fa-2x text-gray-300"></em>
</div>
</div>
</div>
......@@ -100,7 +100,7 @@
<!-- <div class="dropdown no-arrow">
<a class="dropdown-toggle" href="#" role="button" id="dropdownMenuLink" data-toggle="dropdown"
aria-haspopup="true" aria-expanded="false">
<i class="fas fa-ellipsis-v fa-sm fa-fw text-gray-400"></i>
<em class="fas fa-ellipsis-v fa-sm fa-fw text-gray-400"></em>
</a>
<div class="dropdown-menu dropdown-menu-right shadow animated--fade-in"
aria-labelledby="dropdownMenuLink">
......
......@@ -19,31 +19,46 @@
<h4>{{ user.email }}</h4>
<h4>{{ user.biography }}</h4>
<div class="profile-margin"></div>
<table>
<tr>
<td class="profile-data">Instansi</td>
<td>{{ user.instansi }}</td>
</tr>
<td class="profile-data">LinkedIn</td>
<td><a href="https://linkedin.com">{{ user.linkedin }}</a></td>
</tr>
<tr>
<td class="profile-data">Facebook</td>
<td><a href="https://facebook.com">{{ user.facebook }}</a></td>
</tr>
<tr>
<td class="profile-data">Twitter</td>
<td><a href="https://twitter.com">{{ user.twitter }}</a></td>
</tr>
<tr>
<td class="profile-data">Instagram</td>
<td><a href="https://instagram.com">{{ user.instagram }}</a></td>
</tr>
</table>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
instansi
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
{{user.instansi}}
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
LinkedIn
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://linkedin.com">{{ user.linkedin }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Facebook
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://facebook.com">{{ user.facebook }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Twitter
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://twitter.com">{{ user.twitter }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Instagram
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://instagram.com">{{ user.instagram }}</a>
</div>
</div>
<a class="btn btn-primary btn-admin" href="/administration/kelola-admin/">Kembali ke Kelola Admin</a>
</div>
</div>
......
......@@ -18,31 +18,46 @@
<h4>{{ user.email }}</h4>
<h4>{{ user.biography }}</h4>
<div class="profile-margin"></div>
<table>
<tr>
<td class="profile-data">Instansi</td>
<td>{{ user.instansi }}</td>
</tr>
<td class="profile-data">LinkedIn</td>
<td><a href="https://linkedin.com">{{ user.linkedin }}</a></td>
</tr>
<tr>
<td class="profile-data">Facebook</td>
<td><a href="https://facebook.com">{{ user.facebook }}</a></td>
</tr>
<tr>
<td class="profile-data">Twitter</td>
<td><a href="https://twitter.com">{{ user.twitter }}</a></td>
</tr>
<tr>
<td class="profile-data">Instagram</td>
<td><a href="https://instagram.com">{{ user.instagram }}</a></td>
</tr>
</table>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
instansi
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
{{user.instansi}}
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
LinkedIn
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://linkedin.com">{{ user.linkedin }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Facebook
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://facebook.com">{{ user.facebook }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Twitter
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://twitter.com">{{ user.twitter }}</a>
</div>
</div>
<div class="row">
<div class="col-md-6 my-auto" style="font-size: 2rem;">
Instagram
</div>
<div class="col-md-6 my-auto" style="font-size: 1.2rem;">
<a href="https://instagram.com">{{ user.instagram }}</a>
</div>
</div>
<a class="btn btn-primary btn-admin" href="/administration/kelola-kontributor/">Kembali ke Kelola Kontributor</a>
</div>
</div>
......
......@@ -8,7 +8,7 @@ Pratinjau Materi
<!-- Sidebar Toggle (Topbar) -->
<button id="sidebarToggleTop" class="btn btn-link d-md-none rounded-circle mr-3">
<i class="fa fa-bars"></i>
<em class="fa fa-bars"></em>
</button>
<div class="sidebar-brand-text mx-3">Pratinjau Materi</div>
......@@ -53,7 +53,7 @@ Pratinjau Materi
<div class="info-wrapper">
<div class="info" id="1">
<dt class="col col-4">
<p class="info-name">Verifikatur</p>
<p class="info-name"><strong>Verifikatur</strong></p>
</dt>
<dd>
<p class="info-content">{{verification_report.user.name}}</p>
......@@ -61,7 +61,7 @@ Pratinjau Materi
</div>
<div class="info" id="1">
<dt class="col col-4">
<p class="info-name">Waktu Verifikasi</p>
<p class="info-name"><strong>Waktu Verifikasi</strong></p>
</dt>
<dd>
<p class="info-content">{{verification_report.timestamp}}</p>
......@@ -69,7 +69,7 @@ Pratinjau Materi
</div>
<div class="info" id="1">
<dt class="col col-4">
<p class="info-name">Status Materi</p>
<p class="info-name"><strong>Status Materi</strong></p>
</dt>
<dd>
<p class="info-content">{{verification_report.status}}</p>
......
......@@ -15,7 +15,7 @@
<div class="card-header py-3">
<div class="d-flex">
<div class="mr-auto p-2">
<h6 class="m-0 font-weight-bold text-primary">Tabel Daftar Admin</h6>
<h6 id="table-description" class="m-0 font-weight-bold text-primary">Tabel Daftar Admin</h6>
</div>
<div class="p-2">
<a href="/administration/kelola-admin/tambah/" class="accept-button button-decoration button-header">Buat Akun Baru</a>
......@@ -24,7 +24,7 @@
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<table aria-describedby="table-description" class="table table-bordered" id="dataTable">
<thead>
<tr>
<th scope="col">Nama</th>
......
......@@ -13,25 +13,25 @@
<!-- DataTales Example -->
<div class="card shadow mb-4">
<div class="card-header py-3">
<h6 class="m-0 font-weight-bold text-primary">Tabel Daftar Kontributor</h6>
<h6 id="table-description" class="m-0 font-weight-bold text-primary">Tabel Daftar Kontributor</h6>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<table aria-describedby="table-description" class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<thead>
<tr>
<th>Nama</th>
<th>NIK</th>
<th>Instansi</th>
<th>Detail</th>
<th scope="col">Nama</th>
<th scope="col">NIK</th>
<th scope="col">Instansi</th>
<th scope="col">Detail</th>
</tr>
</thead>
<tfoot>
<tr>
<th>Nama</th>
<th>NIK</th>
<th>Instansi</th>
<th>Detail</th>
<th scope="col">Nama</th>
<th scope="col">NIK</th>
<th scope="col">Instansi</th>
<th scope="col">Detail</th>
</tr>
</tr>
</tfoot>
......
......@@ -76,11 +76,11 @@
</div>
<div class="card shadow mb-4">
<div class="card-header py-3">
<h6 class="m-0 font-weight-bold text-primary" id="titleTabelPending">Materi yang Diblokir</h6>
<h6 id="table-description" class="m-0 font-weight-bold text-primary" id="titleTabelPending">Materi yang Diblokir</h6>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table table-bordered" id="dataTablePending" aria-describedby="titleTabelPending">
<table aria-describedby="table-description" class="table table-bordered" id="dataTablePending" aria-describedby="titleTabelPending">
{% if not materi_diblokir %}
Tidak ada materi yang diblokir
{% else %}
......
......@@ -103,7 +103,7 @@
<!-- Sidebar Toggle (Topbar) -->
<button id="sidebarToggleTop" class="btn btn-link d-md-none rounded-circle mr-3">
<i class="fa fa-bars"></i>
<em class="fa fa-bars"></em>
</button>
<div class="sidebar-brand-text mx-3">Diskominfo Kota Depok</div>
......@@ -257,7 +257,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
<!-- Bootstrap core JavaScript-->
......
......@@ -112,7 +112,7 @@
<!-- Sidebar Toggle (Topbar) -->
<button id="sidebarToggleTop" class="btn btn-link d-md-none rounded-circle mr-3">
<i class="fa fa-bars"></i>
<em class="fa fa-bars"></em>
</button>
<div class="sidebar-brand-text mx-3">Diskominfo Kota Depok</div>
......@@ -172,7 +172,7 @@
<label>Deskripsi &nbsp;:</label>{{ form.description }}<br>
<br>
<div class="row">
<button class="primary_btn save" style="border-radius:20px;" type="submit"><i class="far fa-save"></i>
<button class="primary_btn save" style="border-radius:20px;" type="submit"><em class="far fa-save"></em>
Simpan</button>
</div>
</form>
......@@ -182,24 +182,24 @@
<!-- DataTales Example -->
<div class="card shadow mb-4">
<div class="card-header py-3">
<h6 class="m-0 font-weight-bold text-primary">Point Verifikasi Materi</h6>
<h6 id="table-description" class="m-0 font-weight-bold text-primary">Point Verifikasi Materi</h6>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<table aria-describedby="table-description" class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<thead>
<tr>
<th>Judul Verifikasi</th>
<th>Deskripsi</th>
<th></th>
<th scope="col">Judul Verifikasi</th>
<th scope="col">Deskripsi</th>
<th scope="col"></th>
</tr>
</thead>
<tbody>
{% for item in verification_settings %}
<tr>
<th>{{item.title}}</th>
<th>{{item.description}}</th>
<th> </th>
<th scope="col">{{item.title}}</th>
<th scope="col">{{item.description}}</th>
<th scope="col"> </th>
</tr>
{% endfor %}
</tbody>
......@@ -232,7 +232,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
<!-- <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"
......
......@@ -281,9 +281,9 @@
<tbody>
{% for item in items %}
<tr>
<th>{{item.title}} {{item.name}}</th>
<th>{{item.description}}</th>
<th class="verif-buttons">
<th scope="col">{{item.title}} {{item.name}}</th>
<th scope="col">{{item.description}}</th>
<th scope="col" class="verif-buttons">
{% if item.name is None %}
<a
href="/administration/setting/verification/{{ item.id }}/edit"
......@@ -377,9 +377,9 @@
<tbody>
{% for item in items_archived %}
<tr>
<th>{{item.title}} {{item.name}}</th>
<th>{{item.description}}</th>
<th>{{item.archived_by.name}}</th>
<th scope="col">{{item.title}} {{item.name}}</th>
<th scope="col">{{item.description}}</th>
<th scope="col">{{item.archived_by.name}}</th>
</tr>
{% endfor %}
</tbody>
......
......@@ -4,7 +4,7 @@
<html lang="en">
<head>
<title>Digipus</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
......@@ -75,7 +75,7 @@
<nav class="navbar navbar-expand navbar-light bg-white topbar mb-4 static-top shadow">
<!-- Sidebar Toggle (Topbar) -->
<button id="sidebarToggleTop" class="btn btn-link d-md-none rounded-circle mr-3">
<i class="fa fa-bars"></i>
<em class="fa fa-bars"></em>
</button>
<div class="sidebar-brand-text mx-3">Diskominfo Kota Depok</div>
<!-- Topbar Navbar -->
......@@ -139,7 +139,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
<!-- Bootstrap core JavaScript-->
......
......@@ -4,6 +4,7 @@
<html lang="en">
<head>
<title>Digipus</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
......@@ -64,7 +65,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
</body>
......
......@@ -4,7 +4,7 @@
<html lang="en">
<head>
<title>Digipus</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
......@@ -66,7 +66,7 @@
<!-- Scroll to Top Button-->
<a class="scroll-to-top rounded" href="#page-top">
<i class="fas fa-angle-up"></i>
<em class="fas fa-angle-up"></em>
</a>
</body>
......
......@@ -260,6 +260,7 @@
</div>
{% if materi_data.status == "APPROVE" %}
<div id="komentar" class="container-fluid comments-wrapper p-0">
{% if is_authenticated %}
<div class="add-comments col col-8 bg-white shadow-sm rounded p-3 mb-3">
<form method="POST">
{% csrf_token %}
......@@ -272,6 +273,9 @@
</div>
</form>
</div>
{% else %}
<h3>Login terlebih dahulu untuk berkomentar</h3>
{% endif %}
{% for comment in comment_data %}
<div class="col col-8 comment shadow-sm p-3 mb-1 bg-white rounded">
<div class="d-flex bd-highlight mb-3 align-items-center user">
......@@ -284,7 +288,7 @@
{% else %}
<span style="background-color: #{{comment.profile}}" class="profile p-1 bd-highligh"></span>
{% endif %}
<p class="p-1 bd-highligh m-0"><b>{{comment.user.name}}</b></p>
<p class="p-1 bd-highligh m-0"><strong>{{comment.user.name}}</strong></p>
<p class="p-1 bd-highligh m-0"></p>
<p class="timestamp p-1 bd-highligh m-0 text-muted">
{{ comment.timestamp|naturaltime }}
......
<nav class="navbar navbar-dark static-top shadow katalog-navbar"> <!-- Sidebar Toggle (Topbar) -->
<div class="sidebar-brand-text">Digipus</div>
<nav class="navbar navbar-expand-lg navbar-light static-top shadow katalog-navbar"> <!-- Sidebar Toggle (Topbar) -->
<div class="sidebar-brand-text navbar-brand">Digipus</div>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarContent" aria-controls="navbarContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarContent">
<ul class="navbar-nav ml-auto">
<li class="nav-item active">
<a class="nav-link" href="/">Home<span class="sr-only">(current)</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="/forum">Forum</a>
</li>
{% if not request.user.is_authenticated %}
<li class="nav-item">
<a class="nav-link" href="/registrasi">Registrasi</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/login">Login Kontributor</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/login_admin">Login Admin</a>
</li>
{% else %}
<li class="nav-item">
<a class="nav-link" href="/dashboard">Dasbor</a>
</li>
{% if request.user.is_admin %}
<li class="nav-item">
<a class="nav-link" href="/administration">Administrasi</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/profil-admin">Profil</a>
</li>
{% else %}
<li class="nav-item">
<a class="nav-link" href="/profil">Profil</a>
</li>
{% endif %}
<li class="nav-item">
<a class="nav-link" href="/logout">Logout</a>
</li>
{% endif %}
</ul>
</div>
</nav>
\ No newline at end of file
......@@ -2,7 +2,7 @@
<!-- Sidebar Toggle (Topbar) -->
<button id="sidebarToggleTop" class="btn btn-link d-md-none rounded-circle mr-3">
<i class="fa fa-bars"></i>
<em class="fa fa-bars"></em>
</button>
<div class="sidebar-brand-text mx-3">Diskominfo Kota Depok</div>
......
......@@ -49,10 +49,10 @@
<body style="background-color: #f8f8f8;">
{% include 'app/includes/navbar_katalog_materi.html' %}
<!-- Page Content -->
<div class="container">
{% include 'app/includes/navbar_katalog_materi.html' %}
<header class="jumbotron my-4">
<div class="container">
<div class="row header">
......@@ -94,11 +94,13 @@
<div id="collapseOne" class="collapse" aria-labelledby="headingOne"
data-parent="#accordionExample">