section .data code db "ELEE1149", name db "Software Engineering", credits db 15 module_leader db "Seb Blair BEng(H) PGCAP MIET MIHEEM FHEA",
[1] Feature Tests [2] Functional Testing [3] Performace and Load Testing [4] Security Testing
[5] Test Driven Development [6] Unit Testing [7] User Testing
“Enter your surname:” DROP TABLE customer_list;
Feature: Account Holder withdraws cash Scenario: Account has sufficient funds Given The account balance is $100 And the card is valid And the machine contains enough money When the Account Holder requests $20 Then the ATM should dispense $20 And the account balance should be $80 And the card should be returned
abs()
Abs()
# Test abs def test_abs() # Arrange (Setup the testing scenario, mock any data) value = 7.5 # Action (call the function to be tested) result = abs(value) # Assert (Provide the expected outcome) assert result == 7.5
[TestClass] public class MathTests { [TestMethod] public void TestAbs() { // Arrange (Setup the testing scenario, mock any data) double value = 7.5; // Action (call the function to be tested) double result = Math.Abs(value); // Assert (Provide the expected outcome) Assert.AreEqual(7.5, result); } }
name: Upload Python Package on: release: types: [published] permissions: contents: read jobs: release-build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 with: python-version: "3.10" - name: Build release distributions run: python -m pip install build && python -m build - name: Upload distributions uses: actions/upload-artifact@v4 with: name: release-dists path: dist/ pypi-publish: runs-on: ubuntu-latest needs: - release-build permissions: id-token: write environment: name: pypi url: https://pypi.org/project/pylings/${{ github.event.release.name }} steps: - name: Retrieve release distributions uses: actions/download-artifact@v4 with: name: release-dists path: dist/ - name: Publish release distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: packages-dir: dist/