Code Monkey home page Code Monkey logo

polakosz / neptunpro Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 625 KB

The original Neptun is an administrative software for universities developed and forced by the hungarian government. This solution gets the data from the official site and displays that data in a modern UI. Because this application gets the data in an unofficial way there is a chance that not every function will work every time.

Home Page: http://www.sdainformatika.hu/Home/Neptun

C# 100.00%
csharp neptun education hungarian cross-platform scrape xamarin sdainformatika sda

neptunpro's People

Contributors

polakosz avatar

Stargazers

 avatar

Watchers

 avatar  avatar

neptunpro's Issues

Different Neptun versions for different Schools

There is a big chance that not every Neptun owner school will get/install the latest version of the official
Neptun to their servers so it will cause some problems here.

Ideas

Support only (the latest) one build

- Not flexible (should monitor the release cycle of the official app because maybe this is good enought™)
- There is a big chance that we can not support every School when a new release came up (which is a huge problem)

+ Easiest way to maintain the app
+ No need NuGet package for each School

Support only the latest two builds

- Can cause ugly codebase
For eg.:

class ...Deserializer
{
    public int ..Count(string sourceCode)
    {
        if (OfficialApp.BuildNumber == 455)
        {
            RunLatestDeserializer(sourceCode);
        }
        else if (OfficialApp.BuildNumber == 454)
        {
            RunSecondLatestDeserializer(sourCode);
        }
    }
}

- There is a small chance that we can not support every School when a new release came up (which is a huge problem)

+ Bit flexible
+ No need NuGet package for each School

Support every build

- Lot of Google Play / AppStore / Microsoft Store updates (caused by the lot of School NuGet dependency)
- More complex App

                            School NuGet        NeptunPro NuGet
                         ←    ELTE        ←   Neptun Build 455
    Container App        ←    OE          ←   Neptun Build 454
                         ←    ...

- Dependency Hell?
- Maybe this is not even possible (or maybe yes?)

+ Cleanest solution for the problem

Implement Regression tests

Live calls to the webpage

  • Compare the hard coded object (refreshed before started the tests) with the parsed response;
  • Call modification endpoints and validate that the endpoint still exists and change what is should change (for eg.: number of messages in the InBox, add/edit/delete phone number(s), etc.).

Example:

class User : Student
{
    public string Name { get; }
    public int BankAccountBalance { get; }
    public ISchool School { get; }
    public List<Message> Messages { get; }



    public User()
    {
        Name = "Tom PoLáKoSz";
        BankAccountBalance = 20000;
        School = new ObudaiEgyetem();
        Messages = new List<Message>()
        {
            ...
        };
    }
}

...

[TestMethod]
public async void SampleRegressionTests()
{
    _user = new User();

    var loginPage = new LoginPage(_user.School);
    var messagesPage = new MessagesPage(_user.School);

    int maxTryNumber = await loginPage.GetMaxTryNumber();
    await loginPage.LogIn(_user);

    List<Message> messages = await messagesPage.InBox();
    Message specificMessage = await messagesPage.GetMessage(messages[0]);

    CompareSpecificMessage(_user.Messages[0], specificMessage);// maybe this is not valid
    ...
}

[DataSource]
[DataRow(expexted, actual)]
private void CompareSpecificMessage(Message expected, Message actual)
{
    Assert.AreEqual(expected, actual);
}

Community developed notes for students

Villamosságtan is a subject with a lot of failing student on OE.
Maybe with some kind of students developed full note (version controlled .md or gist file from A to Z will help.

Moodle integration

Of course, maybe only OE uses Moodle but with some abstraction this can be useful for every School.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.